Given an integer N which denotes the length of an array, the task is to count the number of subarray and subsequence possible with the… Read More

# Tag Archives: subsequence

Given an array arr[] and a number K which is present in the array at least once, the task is to find the number of… Read More

Given a string of size N and some queries, the task is to find the lexicographically smallest palindromic subsequence of even length in range [L,… Read More

Given an array arr[] of length N and a number K, the task is to find all the subsequences of the array whose sum of… Read More

Given an array arr containing non-negative integers, the task is to print the length of the longest subsequence of Fibonacci numbers in this array. Examples:… Read More

Given an array arr containing non-negative integers, the task is to print the length of the longest subsequence of prime numbers in the array. Examples:… Read More

Given a string str containing only alphabets, the task is to print the longest subsequence of the string str containing only vowels. Examples: Input: str… Read More

Given an array arr[] of positive integers of size N, the task is to find the maximum product of bitonic subsequence of size 3. Bitonic… Read More

Given a string, we have to find out all subsequences of it. A String is a subsequence of a given String, that is generated by… Read More

Given an array arr[] of size N, the task is to find the length of the longest increasing subsequence in the array formed by the… Read More

Given an array arr[] of N integers. The task is to find the length of the contiguous strictly decreasing sequence that can be derieved after… Read More

Given two strings A and B consists of lowercase letters, the task to find the minimum number of subsequence required to form A from B.… Read More

Given an array arr[] of size N and a number K, the task is to find the length of the smallest subsequence such that the… Read More

Given an array arr[] consisting of integers of length N and an integer K (1 ≤ k ≤ N), the task is to find the… Read More

Given two strings A and B consisting of only lowercase letters, the task is to find the minimum number of subsequences required from A to… Read More