Skip to content

Category Archives: Algorithms

Given an array arr[] of size N that contains -1 and all positive integers, the task is to modify the array and print the final… Read More
Given an array of positive integers arr[] of length N and a query array query[] of length M, the task is to find the maximum… Read More
Given an array A[] of N positive integers and 3 integers X, Y, and Z, the task is to check if there exist 4 indices… Read More
These are the special type of recursive functions, where the last statement executed inside the function is the call to the function itself. Advantages of… Read More
Given an array B[] of length N, the task is to print an array A[] such that for every ith element B[i] is gcd of… Read More
Given a binary string S, the task is to count the substrings having the number of 0s and 1s in the ratio of X :… Read More
Given two arrays A[] and B[] of length N and M respectively and a prime number X, the task is to find the number of… Read More
Given an array A[] of size N, the task is to check whether the sequence can be made strictly increasing by performing the following operation… Read More
Given a 2-D array A[][] of size N×3, where each element of the array consists of {x, y, r}, where x and y are coordinates… Read More
Given two positive integers A and B, the task is to find the number of integers X such that (A⊕X ) & B = 0… Read More
Given an array A[] of size N, and an integer X, the following operation can be performed on that array: Choose any element, say Y… Read More
The XOR operation between two numbers P and Q can be looked in a different way as the bitwise sum modulo 2 on the bits… Read More
A Pseudocode is defined as a step-by-step description of an algorithm. Pseudocode does not use any programming language in its representation instead it uses the… Read More
HCL Technologies Ltd is one of the leading global IT services companies that helps global enterprises re-imagine and transform their businesses through Digital technology transformation.… Read More
Given a positive integer N, the task is to tell whether it’s an anti-prime number or not. Anti-Prime Numbers (Highly Composite Number): A positive integer… Read More

Start Your Coding Journey Now!