## Longest Increasing Subsequence using Longest Common Subsequence Algorithm

Given an array arr[] of N integers, the task is to find and print the Longest Increasing Subsequence. Examples: Input: arr[] = {12, 34, 1,… Read More »

- Check whether two strings contain same characters in same order
- Implement a Dictionary using Trie
- Minimum rotations required to get the same String | Set-2
- Sort an array of strings based on the frequency of good words in them
- Count number of distinct substrings of a given length
- Find minimum length sub-array which has given sub-sequence in it
- Find if a binary matrix exists with given row and column sums
- Longest Increasing Subsequence using Longest Common Subsequence Algorithm
- Minimum given operations required to convert a given binary string to all 1's
- Longest prefix in a string with highest frequency
- Find the element in the matrix generated by given rules
- Sum of the digits of square of the given number which has only 1's as its digits

Given an array arr[] of N integers, the task is to find and print the Longest Increasing Subsequence. Examples: Input: arr[] = {12, 34, 1,… Read More »

Given a number represented as a string str consisting of the digit 1 only i.e. 1, 11, 111, …. The task is to find the… Read More »

Given a binary number as a string str of length L. The task is to find the minimum number of operations needed so that the… Read More »

Implement a dictionary using Trie such that if the input is a string representing a word, the program prints its meaning from the prebuilt dictionary.… Read More »

Given a set of product reviews (R) by different customers and a string S containing good words separated by a _, the task is to… Read More »

Given an array arr[] of N elements, the task is to find the length of the smallest sub-array which has sequence {0, 1, 2, 3,… Read More »

Given an array Row[] of size R where Row[i] is the sum of elements of the ith row and another array Column[] of size C… Read More »

Given some rules to generate an N * N matrix mat[][] and two integers R and C, the task is to find the element at… Read More »

Given a string, we need to find the minimum number of rotations required to get the same string. In this case, we will only consider… Read More »

Given a string, find a prefix with the highest frequency. If two prefixes have the same frequency then consider the one with maximum length. Examples:… Read More »

Given two strings s1 and s2, the task is to find whether the two string contain the same characters that occur in the same order.… Read More »

Given a string S of length N consisting of lower-case English albhabets and an integer ‘l’, find the number of distinct sub-strings of length ‘l’… Read More »

Given an integer N, the task is to find the length of the longest substring containing only 4’s from the first N characters of the… Read More »

Given a string str, the task is to find the longest prefix which is also the suffix of the given string. The prefix and suffix… Read More »

Given a number N, the task is to print the string of ‘A’ and ‘B’ corresponding to that number. If we represent all numbers as… Read More »