Queries to evaluate the given equation in a range [L, R]
Given an array arr[] consisting of N integers and queries Q[][] of the form {L, R} where 0 ≤ L < R ≤ N –… Read More »
Given an array arr[] consisting of N integers and queries Q[][] of the form {L, R} where 0 ≤ L < R ≤ N –… Read More »
Given an array A[], for each element in the array, the task is to find the sum of all the previous elements which are strictly… Read More »
Given two numbers L and R, the task is to find two distinct minimum positive integers X and Y such that whose LCM lies in… Read More »
Given an array arr[] of N positive integers and an integer K. The task is to create a set of prime numbers such that sum… Read More »
Given an array A[] of N integers, the task is to find the relative rank for each element in the given array. The relative rank… Read More »
Given a number N, the task is to find two numbers a and b such that a + b = N and LCM(a, b) is… Read More »
Given a number N and for any number K for a series formed as K, K + 1, K + 2, K + 3, K… Read More »
Given a string S with lowercase alphabets only and Q queries where each query contains a pair {L, R}. For each query {L, R}, there… Read More »
Given an integer array arr[] of size N, the task is to construct an array consisting of N+1 strings of length N such that arr[i]… Read More »
Given a string str, the task is to find the number of distinct substrings that are placed consecutively in the given string.Examples: Input: str =… Read More »
Given a number N, the task is to calculate the total number of corresponding different bit in the binary representation for every consecutive number from… Read More »
Given an array arr[] of positive integers and an number K, the task is to find the minimum and maximum values of Bitwise operation on… Read More »
Competitive Programming….what comes to your mind first…? most probably you associate the idea of solving the coding questions on GeeksforGeeks, Codechef, Topcoder, Codeforces, Hackerank, etc.… Read More »
Given an N-ary Tree rooted at 1, and an array val[] consisting of weights assigned to every node, and a matrix Q[][], consisting of queries… Read More »
Given a 2D matrix tsp[][], where each row has the array of distances from that indexed city to all the other cities and -1 denotes… Read More »