Skip to content

Category Archives: Algorithms

Given a binary matrix Mat[][] of size N*N, the task is to find the minimum number of flips to be performed such that the matrix… Read More
Given three integers X, Y, and Z. the task is to find the minimum distance between any two multiples of the given integers. Note: Common… Read More
Given a binary array a[] or size N and an integer K, the task is to find the longest subarray consisting of only 1s or… Read More
Given an array of size N. Consider all the subarrays starting at each index from [0, N – 1]. Determine the length of the smallest… Read More
Given the number of pages in N different books and M students. Every student is assigned to read some books that can be consecutive or… Read More
Given an integer N denoting the size of an array and two arrays containing Bitwise AND and Bitwise OR of adjacent elements of the array… Read More
Given a target string S consisting of lowercase alphabets, the task is to make this string by performing some operation on an empty string such… Read More
Given an array Arr[] of N integers and an integer K, the task is to find if it is possible to make the count of… Read More
Given an array A[] of positive integers, print all the unique non-empty subsets of the array  Note: The set can not contain duplicate elements, so… Read More
Given two integers X and Y, and an integer K, the task is to find the minimum number of operations to make X equal to… Read More
Given an array of integers arr[], the task is to find the maximum number of the indices having values greater than the sum of the neighbours… Read More
Given a binary array A[] of size N, the task is to find the minimum number of subarrays that need to be reversed to sort… Read More
Given two numbers M and N denoting the number of rows and columns of a matrix A[] where A[i][j] is the sum of i and… Read More
Given an integer N (N > 2), the task is to generate a binary string of size N that consists of equal numbers of “10”… Read More
Given an array arr[] of N integers. the task is to find the minimum number of operations required to make all the elements of the… Read More

Start Your Coding Journey Now!