## Longest sub-sequence of array containing Lucas numbers

Given an array arr[] of N elements, the task is to find the length of the longest sub-sequence in arr[] such that all the elements… Read More »

- Make all numbers of an array equal
- Program to find the Hidden Number
- Reach the numbers by making jumps of two given lengths
- Largest palindromic number in an array
- Check if a number is perfect square without finding square root
- Find the unit place digit of sum of N factorials
- Check if a number can be expressed as a^b | Set 2
- Puzzle | Cut Blue Painted Cube
- Sum of the first N Prime numbers
- Minimum operations required to make all the array elements equal
- Sum of XOR of all subarrays
- Sum of minimum elements of all subarrays
- A Sum Array Puzzle
- Check if it is possible to reach a number by making jumps of two given length
- Generate all rotations of a number
- Puzzle | Neighbors in a round table
- Number of array elements derivable from D after performing certain operations
- Find K Closest Points to the Origin
- Minimum number of sets with numbers less than Y
- Program to find minimum number of lectures to attend to maintain 75%
- Color N boxes using M colors such that K boxes have different color from the box on its left
- Check if a number is a Mystery Number
- Sum of all Primes in a given range using Sieve of Eratosthenes
- Sum of the multiples of two numbers below N
- Count of pairs (x, y) in an array such that x < y
- Immediate smallest number after re-arranging the digits of a given number
- Find the Nth term of the series 14, 28, 20, 40,.....
- Find elements of array using XOR of consecutive elements
- Find a point such that sum of the Manhattan distances is minimized
- Minimum Increment / decrement to make array elements equal

Given an array arr[] of N elements, the task is to find the length of the longest sub-sequence in arr[] such that all the elements… Read More »

Given an array containing N elements, each element is either 1 or 2. The task is to find out whether the array can be divided… Read More »

Given three integers N, D and K. The task is to check whether it is possible to make a tree with exactly N vertices, D… Read More »

Given a NxN 2-D matrix, the task to find the sum of all the submatrices. Examples: Input : arr[] = {{1, 1}, {1, 1}}; Output… Read More »

Given a range [L, R], the task is to find a pair (X, Y) such that L ≤ X < Y ≤ R and X… Read More »

Given an array of n length. The task is to check if the given array can be split into an odd number of sub-segment starting… Read More »

Given an array Arr[] of N integers. The task is to find minimum number of elements needed to be removed from the array, so that… Read More »

Given an integer N, the task is to check whether N the given number can be made a perfect square after adding 1 to it.… Read More »

Given an undirected complete graph of N vertices where N > 2. The task is to find the number of different Hamiltonian cycle of the… Read More »

Given a directed graph and a node X. The task is to find the minimum number of edges that must be added to the graph… Read More »

Given an array arr[] of N integers and an integer M where N % M = 0. The task is to find the minimum number… Read More »

Given an array arr[], the task is to find the minimum number of elements that must be removed to make the array good. A sequence… Read More »

Given a range [L, R] and two positive integers N and M. The task is to count the numbers in the range containing only non-zero… Read More »

Given three positive integers N, L and R. The task is to find the number of ways to form an array of size N where… Read More »

Given a range [L, R] where L ≤ R, the task is to generate a random permutation of the sequence [L, L + 1, L… Read More »