Skip to content

Tag Archives: cpp-map

Given an array arr[] of size N and an integer T representing the count of threads, the task is to find all non-repeating array elements… Read More
Given an array arr[] of size N, the task is to find the minimum count of array elements required to be removed such that frequency… Read More
Given a string str, the task is to find the maximum count of common non-repeating characters that can be obtained by partitioning the given string… Read More
Given an array arr[] of size N, the task is to check if any subarray from the given array can be made a palindrome by… Read More
Given two integers N and M and an 2D array arr[], the task is to construct the smallest possible integer of N digits ( without… Read More
Given a binary matrix, mat[][] of dimensions N * M, the task is to maximize the count of rows consisting only of equal elements by… Read More
Map in STL: Maps are associative containers that store elements in a mapped fashion. Each element has a key value and a mapped value. No… Read More
Given a binary array arr[] of size N and two players, A and B. The task is to minimize the score for player A by… Read More
Given a string S of length N and an integer K, the task is to find the minimum character replacements required to make the string… Read More
Given two arrays arr[] and brr[] of length N, the task is to find the minimum number of swaps of the same indexed elements required… Read More
Given an array arr[] of size N. In each operation, pick an array element X and remove all array elements in the range [X –… Read More
Given an integer N and an array arr[] consisting of M integers from the range [1, N]. (M – 1) operations need to performed. In… Read More
Given an array arr[] consisting of N integers, the task for each array element arr[i] is to print the sum of |i – j| for… Read More
Given an array arr[] consisting of N non-negative integers, the task is to find the number of operations required to make all array elements equal.… Read More
Given an array, arr[] of size N, the task is to count the number of unordered pairs such that Bitwise AND and Bitwise OR of… Read More