Skip to content

Tag Archives: cpp-map

Given an array arr[] of N integers such that no element is 0 in that array, the task is to find the minimum number of… Read More
Given two arrays, A[] and B[], the task is to check if they are equal or not. Arrays are considered equal if any permutation of… Read More
What is a Map? Before learning the data structure used by a map, let us have an overlook of map. Map is the part of… Read More
Given an array arr[] containing N email addresses with different domains, the task is to find the unique domains and their frequencies from the list… Read More
Maps are associative containers that store elements in a mapped fashion. Each element has a key value and a mapped value. No two mapped values… Read More
Given a string s of length N, containing digits written in words but in jumbled form, the task is to find out the digits present… Read More
Given an empty array A[] & Q queries of two types 1 and 2 represented by queries1 and queries2 respectively, the task is to find… Read More
Given an array arr[], integer M and an array query[] containing Q queries, the task is to find the query[i]th occurrence of Mth most frequent… Read More
Given an array A[] containing N elements of an array and their frequency in that array (say arr[]), the task is to find the median… Read More
Map is an associative container available in the C++ Standard Template Library(STL) that is used to store key-value pairs. Let’s see the different ways to… Read More
Given two strings str1 and str2, the task is to check if the two strings are isomorphic to each other. Two strings str1 and str2… Read More
Given a binary tree, the task is to: Print all the leaf nodes and then delete them all.  Repeat this process till the tree becomes… Read More
Given a sentence S and a string B having distinct characters, find a string by joining the words of S according to given conditions:- Choose… Read More
Given two maps map1 and map2 having a string as the key and arrays of integers as values, the task is to merge them in… Read More
Given an array arr[] containing integers. The task is to find the largest positive integer x missing from the array such that min(arr[]) < x… Read More

Start Your Coding Journey Now!