## Find sub-arrays from given two arrays such that they have equal sum

Given two arrays A[] and B[] of equal sizes i.e. N containing integers from 1 to N. The task is to find sub-arrays from the… Read More »

- Make all numbers of an array equal
- Sum of XOR of all subarrays
- Nth number whose sum of digit is multiple of 10
- Count common characters in two strings
- Merge K sorted arrays of different sizes | ( Divide and Conquer Approach )
- Sort an array without changing position of negative numbers
- Given two arrays count all pairs whose sum is an odd number
- Operations required to make the string empty
- Java ArrayList to print all possible words from phone digits
- Find minimum difference between any two elements | Set 2
- Interactive Problems in Competitive Programming
- Check whether two strings contain same characters in same order
- Program to find the kth character after decrypting a string
- Find two numbers whose divisors are given in a random order
- Sum of bitwise AND of all subarrays
- Total number of possible Binary Search Trees using Catalan Number
- Count of all possible values of X such that A % X = B
- Find sub-arrays from given two arrays such that they have equal sum
- Maximize the happiness of the groups on the Trip
- Find the minimum number of operations required to make all array elements equal
- Find the number of distinct pairs of vertices which have a distance of exactly k in a tree
- Check if a Queen can attack a given cell on chessboard
- Spanning Tree With Maximum Degree (Using Kruskal's Algorithm)
- Maximum subarray sum by flipping signs of at most K array elements
- Find the minimum number of elements that should be removed to make an array good
- Find the minimum number of preprocess moves required to make two strings equal
- Count how many times the given digital clock shows identical digits
- Shortest path on a Square
- Replace array elements by sum of next two consecutive elements
- Number of ways of scoring R runs in B balls with at most W wickets

Given two arrays A[] and B[] of equal sizes i.e. N containing integers from 1 to N. The task is to find sub-arrays from the… Read More »

Given two integer N and K, the task is to find the permutation P of first N natural numbers such that there are exactly K… Read More »

Given an array of size N in which initially all the elements are 0(zero). The task is to count the number of 1’s in the… Read More »

Given two arrays of N and M integers. The task is to find the number of unordered pairs formed of elements from both arrays in… Read More »

Given a number N, there are two steps to be performed. At odd step, XOR the number with any 2^M-1, where M is chosen by… Read More »

Given an array of strings arr[] and given some queries where each query consists of a string str and an integer k. The task is… Read More »

Given a string S, the task is to check if we can make the string lexicographically smaller by reversing any sub-string of the given string.… Read More »

Just like base 2 Binary numeral system having 0s and 1s as digits, Ternary(Trinary) Numeral System is a base 3 number system having 0s, 1s… Read More »

Given a binary string str, the task is to find the largest power of 2 that divides the decimal equivalent of the given binary number.… Read More »

Given two integers K and N, the task is to count the number of ways to arrange K different objects taking N objects at a… Read More »

Given a circular ring which has marking from 1 to N. Given two numbers A and B, you can stand at any place(say X) and… Read More »

Given a 2-D array of order N X M array elements, the task is to check if we can select a number from every row… Read More »

Given two arrays A[] and B[] of N and M integers respectively. Also given is a N X M binary matrix where 1 indicates that… Read More »

Given an array arr[] of N positive integers. The task is to find the maximum possible value of a[i] % a[j] over all pairs of… Read More »

Given an integer N. The task is to find the number of divisors of all the numbers in the range [1, N]. Examples: Input: N… Read More »