A simple sentence if syntactically correct if it fulfills given rules. The following are given rules. Sentence must start with a Uppercase character.
Category - C++ programming
Given two sets represented by two arrays, how to check if the given two sets are disjoint or not? It may be assumed that the given arrays.
Given arrival and departure times of all trains that reach a railway station, find the minimum number of platforms required.
An array of distinct integers, find length of the longest sub array which contains numbers that can be arranged in a continuous sequence.
Given two positive integers n and k, print all increasing sequences of length k such that the elements in every sequence are from first n natural numbers.
Given two strings str1 and str2, find if str1 is a subsequence of str2. A subsequence is a sequence that can be derived from another sequence by deleting
Given a snake and ladder board, find the minimum number of dice throws required to reach the destination or last cell from source or 1st cell.
There are given n ropes of different lengths, we need to connect these ropes into one rope. The cost to connect two ropes is equal to sum of their lengths.
This is mainly an application of Catalan Numbers. Total possible valid expressions for input n is n/2’th Catalan Number if n is even and 0 if n is odd.
Given an array of random numbers, find longest monotonically increasing subsequence (LIS) in the array.If you want to understand the O(NlogN) approach.