## Maximize count of corresponding same elements in given permutations using cyclic rotations

Given two permutations P1 and P2 of numbers from 1 to N, the task is to find the maximum count of corresponding same elements in… Read More »

- Longest permutation subsequence in a given array
- Check if an Array is a permutation of numbers from 1 to N
- Minimum cost to make an Array a permutation of first N natural numbers
- Sort permutation of N natural numbers using triple cyclic right swaps
- Find the Number of Permutations that satisfy the given condition in an array
- Minimum steps to convert an Array into permutation of numbers from 1 to N
- Count of subarrays of size K which is a permutation of numbers from 1 to K
- Print the two possible permutations from a given sequence
- Count of common subarrays in two different permutations of 1 to N
- Count of K-size substrings having palindromic permutations
- Sort decreasing permutation of N using triple swaps
- Print all permutations of a number N greater than itself
- Permutation of first N positive integers such that prime numbers are at prime indices | Set 2
- Check if the given permutation is a valid BFS of a given Tree
- Count of K-countdowns in an Array
- Number of ways to paint K cells in 3 x N grid such that no P continuous columns are left unpainted
- Permutation of given string that maximizes count of Palindromic substrings
- Check if a Sequence is a concatenation of two permutations
- Check if an Array is a permutation of numbers from 1 to N : Set 2
- Find the K-th Permutation Sequence of first N natural numbers
- Find the minimum permutation of A greater than B
- Find the N-th lexicographic permutation of string using Factoradic method
- Count of possible permutations of a number represented as a sum of 2's, 4's and 6's only
- Check if there exists a permutation of given string which doesn't contain any monotonous substring
- Number of valid indices in the permutation of first N natural numbers

Given two permutations P1 and P2 of numbers from 1 to N, the task is to find the maximum count of corresponding same elements in… Read More »

Given two integer N and K, the task is to find the size of the smallest string that contains all permutations of length N that can… Read More »

Given a permutation P of size N, having values from 1 to N. the task is to find the minimum number of adjacent swaps required… Read More »

Given a string S, print those permutations of string S which are lexicographically greater than S. If there is no such permutation of string, print… Read More »

Problem Statement: Design a Definite Finite Automata for accepting the permutation of Three a’s and Three b’s over the input {a, b} Input: S =… Read More »

Given an array of strings arr[] which contains patterns of characters and denoting any set of characters including empty string. The task is to find… Read More »

Given an integer K and an index array arr[] of length N which contains elements in the range [1, N], the task is to find… Read More »

Given a string str consist of only lowercase alphabets and an integer K, the task is to count the number of substrings of size K… Read More »

Given an array arr[] of size N which contains the permutations of the N natural numbers, the task is to sort the permutations of N… Read More »

Given a tree with N nodes numbered from 1 to N and an permutation array of numbers from 1 to N. Check if it is… Read More »

Given two arrays A and B of the same length N, filled with a permutation of natural numbers from 1 to N, the task is… Read More »

Given an integer N, the task is to find out the number of permutations in which N can be represented as a sum of 2s,… Read More »

Given an array arr of distinct integers, the task is to find count of sub-arrays of size i having all elements from 1 to i,… Read More »

Given a number N, our task is to print those permutations of integer N which are greater than N. Examples: Input: N = 534 Output:… Read More »

Given an array arr[] of length N and a number K, the task is to count the number of K-countdowns in the array. A contiguous… Read More »