Skip to content

Category Archives: Mathematical

Given an array arr[] of size N. The task is to count the number of unique subsets.  Examples: Input: arr[] = {1, 2, 2}Output: 6Explanation:… Read More
Given an NxN square matrix M[][]. The task is to check whether the matrix M is a zero division matrix or not. A matrix is… Read More
Given a matrix arr[][] of size M*N containing only positive integers, the task is to check if every row contains all the integers from 1… Read More
Given an array arr[] of N integers where ith element represents the amount of water required by the plant at ith index and an integer… Read More
Given an array arr[] of N integer pairs and an integer K, the task is to find the indices of the K largest pairs in… Read More
Given three values, N, L and R, the task is to calculate the sum of binomial coefficients (nCr) for all values of r from L… Read More
Given an array arr[] of length N, the task is to replace all subarrays of only even elements by their length if the length is… Read More
Given two integers A and B, the task is to count the possible values of K such that A%K = B%K. If the count is… Read More
Given three positive integers N, K, and M. The task is to find Kth largest N digit number divisible by M.  Note: K will be… Read More
Find an arrangement of M colors for N indices such that no two adjacent indices have same color and each color can be used at… Read More
Given a string str denoting a sequence of moves. The task is to check if the moves are repeated an infinite number of times then… Read More
Given an array A[] of length N, the task is to find the minimum size of the array after selecting and removing distinct element pairs… Read More
Given an array arr[] having N pair of integers of the form (x, y), the task is to maximize the sum y values in selected… Read More
Given an array arr[] of size N, the task is to make all elements equal by applying the operation given below any number of times… Read More
Given an array containing digits[], where each element is a single digit integer. The array may contain duplicates. The task is to find all the… Read More

Start Your Coding Journey Now!