# Category Archives: Searching

Given a binary tree, a target node and a positive integer K on it,  the task is to find the sum of all nodes withinâ€¦ 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
Given an array arr[] of size N representing the time taken by a person to complete a task. Also, an array restTime[] which denotes theâ€¦ Read More
Given an array arr[] of size N and an integer K, the task is to minimize the value of the maximum element of the arrayâ€¦ Read More
Given an array A[] having N non-negative integers, find a pair of indices i and j such that the absolute difference between them is sameâ€¦ Read More
Given an array, arr[] of size N and a positive integer D, the task is to find the position i of an element in arr[]â€¦ Read More
Given a string str and K pair of characters, the task is to check if string str can be made Palindrome, by replacing one characterâ€¦ Read More
Given a sorted array arr[] of size N, where arr[i] denotes the starting position of a sequence, the task is to find the minimum numberâ€¦ Read More
Given an array task[] of size N denoting amount of work to be done for each task, the problem is to find the minimum amountâ€¦ Read More
Given an array Arr[ ] of N integers where 1 â‰¤ N â‰¤ 105. The task is to choose any number of elements from theâ€¦ Read More
Given an array arr[] of size N, the task is to find the minimum value range [L, R] such that: The array can be dividedâ€¦ Read More
Given a 2D array A[][] of size N x 2 where: Every element lies between [1, N]. A[i][0] signifies that there must be at mostâ€¦ Read More
Given a Grid of size NxM, and two integers X and Y, the task is to count the minimum number of rows between the rowâ€¦ Read More
Given a binary tree of N nodes. Count the frequency of an integer K in the binary tree. Examples:  Input: N = 7, K =â€¦ Read More
Given a binary tree having N nodes, the task is to find the level having the maximum number of setbits. Note: If two levels haveâ€¦ Read More