## Minimum steps needed to cover a sequence of points on an infinite grid

Given an infinite grid, initial cell position (x, y) and a sequence of other cell position which needs to be covered in the given order.… Read More »

- Maximize the value of A by replacing some of its digits with digits of B
- Check if array can be divided into two sub-arrays such that their absolute difference is K
- Minimum spanning tree cost of given Graphs
- Make all elements of an array equal with the given operation
- Find the repeating and the missing number using two equations
- Find the values of X and Y in the Given Equations
- Count pieces of circle after N cuts
- Count triplet pairs (A, B, C) of points in 2-D space that satisfy the given condition
- Reconstruct the array by replacing arr[i] with (arr[i-1]+1) % M
- Number of pairs with Bitwise OR as Odd number
- Count pairs with Bitwise-AND as even number
- Maximize the value of x + y + z such that ax + by + cz = n
- Check if N can be represented as sum of integers chosen from set {A, B}
- Check if an array of 1s and 2s can be divided into 2 parts with equal sum
- Split an array into groups of 3 such that X3 is divisible by X2 and X2 is divisible by X1
- Divide an isosceles triangle in two parts with ratio of areas as n:m
- Number of solutions for x < y, where a <= x <= b and c <= y <= d and x, y are integers
- Split N^2 numbers into N groups of equal sum
- Sum of all even numbers in range L and R
- Number of words in a camelcase sequence
- Represent a number as a sum of maximum possible number of Prime Numbers
- Maximize number of nodes which are not part of any edge in a Graph
- Count the number of common divisors of the given strings
- Absolute difference between the first X and last X Digits of N
- Check if a number can be represented as a sum of 2 triangular numbers
- Maximum sum after repeatedly dividing N by a divisor
- Partiton N into M parts such that difference between Max and Min part is smallest
- Count subarrays consisting of only 0's and only 1's in a binary array

Given an infinite grid, initial cell position (x, y) and a sequence of other cell position which needs to be covered in the given order.… Read More »

Given the first two digits of a large number digit1 and digit2. Also given a number c and the length of the actual large number.… Read More »

Prerequisites: Generating Functions, Fibonacci Numbers, Methods to find Fibonacci numbers. The method of using Generating Functions to solve the famous and useful Fibonacci Numbers‘ recurrence… Read More »

Given a number N, place numbers from the range [1, N2] in an NxN matrix such that sum in every row is equal. Examples: Input:… Read More »

Prerequisites: Triangular numbers Tetrahedral numbers Given a value n, and the task is to print tetrahedral number series up to nth term. Examples: Input: 5… Read More »

Given the length, width, and height of a triangular prism, the task is to find the volume of the triangular prism. Examples: Input: l =… Read More »

Given an array of size N and Q queries, each query consists of L, R, and K(consider 1 based-indexing for L and R). The task… Read More »

Given a function gcd(a, b) to find GCD (Greatest Common Divisor) of two number. It is also known that GCD of three elements can be… Read More »

Given the side of an Icosahedron. The task is to find the area and volume of the given Icosahedron. Examples : Input : a =… Read More »

Given a number N and the min and max range. Given N values of a and b respectively. The task is to count the number… Read More »

Given four arrays of 3 numbers each which represents sides and angles of two triangles. The task is to check if the two triangles are… Read More »

Given a railway seat number, the task is to check whether it is a valid seat number or not. Also print its berth type i.e… Read More »

Given a very large number, the task is to write a program to compute its square. Examples: Input: 9999 Output: 99980001 9999*9999 = 99980001 Input:… Read More »

Given the side of a square. The task is to find the area of an inscribed circle in a square. Examples: Input : a =… Read More »

Given three numbers a, b and m where 1<=a, m<=10^6. Given very large 'b' containing up to 10^6 digits and m is a prime number,… Read More »