## Count number of ways to cover a distance | Set 2

Given a distance N. The task is to count the total number of ways to cover the distance with 1, 2 and 3 steps. Examples:… Read More »

- Minimum number of Fibonacci jumps to reach end
- Number of shortest paths to reach every cell from bottom-left cell in the grid
- Maze With N doors and 1 Key
- Number of Subsequences with Even and Odd Sum
- Maximum number of given operations to remove the entire string
- Maximum Sequence Length | Collatz Conjecture
- Subsequence X of length K such that gcd(X[0], X[1]) + (X[2], X[3]) + ... is maximized
- Optimal Strategy for a Game | Set 3
- Count number of ways to get Odd Sum
- Divide an array into K subarray with the given condition
- Counts Path in an Array
- Minimum increment or decrement operations required to make the array sorted
- Count of subsets not containing adjacent elements
- Fractional Knapsack Queries
- Longest Increasing Subsequence using Longest Common Subsequence Algorithm
- Count total set bits in all numbers from 1 to N | Set 3
- Largest sub-matrix with all equal elements
- Minimize the cost of partitioning an array into K groups
- Minimum halls required for class scheduling
- Convert N to M with given operations using dynamic programming
- Maximum perimeter of a square in a 2D grid
- Count of N-digit numbers in base K with no two consecutive zeroes
- Count number of Special Set
- Count number of ways to arrange first N numbers

Given a distance N. The task is to count the total number of ways to cover the distance with 1, 2 and 3 steps. Examples:… Read More »

Given an integer N, the task is to count the number of binary strings possible such that there is no substring of length ≥ 3… Read More »

Given an N*M matrix containing only 0s and 1s, the task is to count the number of square submatrices containing all 1s. Examples: Input: arr[][]… Read More »

Given an array arr[] of length N, the task is to find the number of strictly increasing sub-sequences in the given array. Examples: Input: arr[]… Read More »

Given an array of integer arr[] and an integer k, the task is to find the median of each window of size k starting from… Read More »

Given a N x M matrix where N is the number of rows and M is the number of columns in the given matrix and… Read More »

Given a number N, the task is to build N blocks from 1 block by performing following operation: Double the number of blocks present in… Read More »

Given three integers X, Y and Z, the task is to find the sum of all the numbers formed having 4 atmost X times, 5… Read More »

Given an array arr[] of size N. The task is to find the size of the set of numbers from the given array such that… Read More »

Given a binary tree of 0s and 1s, the task is to find the maximum number of 1s in any path in the tree. The… Read More »

Given a sorted array of length ‘N’ and an integer ‘K'(K<N), the task is to remove exactly 'K' elements from the array such that sum… Read More »

Given a binary string S of length N, the task is to find the length of the longest sub-sequence in it which is divisible by… Read More »

Given a binary string S of length N, the task is to find the number of sub-sequences of non-zero length which are divisible by 3.… Read More »

Given a character X and a string Y of length N and the task is to find the number of ways to convert X to… Read More »

Given an array arr[], the task is to find out the maximum obtainable value. The user is allowed to add or multiply the two consecutive… Read More »