The Wayback Machine - https://web.archive.org/web/20230312022609/https://www.geeksforgeeks.org/category/competitive-programming/
Skip to content

Category Archives: Competitive Programming

Given a Binary Search Tree with unique node values and a target value. Find the node whose data is equal to the target and return… Read More
Given an integer array A[] of size N and integer k. For a fixed value p, choose an index i (1 ≤ i ≤ n)… Read More
Given a matrix M[][] having R rows and C columns, the task is to return a matrix X[][] in which X[i][j] represents the number of… Read More
Given two matrices M1[][] and M2[][] of size R * C along with an integer X. In one operation select any cell of M1 let’s… Read More
Given counts of x, y, and z, the task is to find the maximum number of triplets that can be made from the count of… Read More
Given an array X[] of length N along with an integer K. Then the task is to choose a sub-sequence to maximize the sum by… Read More
Given three points X, Y, and Z of a 2D plane, the task is to check if it is possible to move from X to… Read More
Given a binary matrix Matrix[][] of size M * N. Then the task is to return YES or NO, by checking whether the structure follows… Read More
Given an array A[] of length N along with an integer X, the task is to make the parity of all the elements in A[]… Read More
Given two integers X and Y such that X+Y is even, Which denotes the initial position of the bishop on a chessboard of 8 x… Read More
Given two numbers L and R, the task is to find the count of all numbers in a given range [L, R] that are divisible… Read More
Given an array X[] of length N (N ≥ 2 ), the task is to output an array of maximum bitwise AND over all the… Read More
 Given two arrays X[] and Y[] of length N(N >= 1), where X[] contains the height till which curtains are hung on the wall and… Read More
Given a matrix M[][] of size N * M containing characters 0 and X. You have to choose a sub-matrix of 2*2 size, which doesn’t… Read More
Given a string S of characters R, L, U, D, along with integers X1, Y1, X2, Y2. In String S, ‘R’, ‘L’, ‘U’, and’D’ denote… Read More

Start Your Coding Journey Now!