Union of Arrays with Duplicates
Given two arrays a[] and b[],the task is to find the number of elements in the union between these two arrays. The Union of […]
Given two arrays a[] and b[],the task is to find the number of elements in the union between these two arrays. The Union of […]
Given two integer arrays a[] and b[], you have to find the intersection of the two arrays. Intersection of two arrays is said to be elements that are
Given an array arr[] of positive integers and another integer target. Determine if there exists two distinct indices such that the sum of
Given a strictly sorted 2D matrix mat[][] of size n x m anda number x. Find whether the number x is present in the matrix or not.Note:
Given a 2D integer matrix mat[][] of size n x m, where every row and column is sorted in increasing order and
Given a sorted array of distinct positive integers arr[], we need to find the kth positive number that is missing from arr[]. Examples
You are given an array arr[] of integers, where each element arr[i] represents the number of pages in the ith book. You also have
You are given an array with unique elements of stalls[],which denote the position of a stall. You are also given an
Given an array arr[] where no two adjacent elements are same, find the index of a peak element. An element is considered to be a peak if it
Given two sorted arrays a[] and b[] in non-decreasing order. Merge them in sorted order without using any extra space. Modify a so that it contains the
Given a 2D array intervals[][] of representing intervals where intervals [i] = [starti, endi ]. Return the minimum number of intervals you need to remove to make
Geek has an array ofnon-overlapping intervals intervals where intervals[i] = [starti, endi] represent the start and the end of the ith event and intervals is sorted in ascending