Is Subsequence Leetcode Solution

Problem Statement In this problem, we are given two different strings. The goal is to find out whether the first string is a subsequence of the second. Examples first string = “abc” second string = “mnagbcd” true first string = “burger” second string = “dominos” false Approach(Recursive) This is easy …

Read moreIs Subsequence Leetcode Solution

Unique Paths Leetcode Solution

The problem Unique Paths Leetcode Solution states that you are given two integers representing the size of a grid. Using the size of the grid, the length, and breadth of the grid. We need to find the number of unique paths from the top left corner of the grid to …

Read moreUnique Paths Leetcode Solution

Maximum Length of Repeated Subarray

In problem “Maximum Length of Repeated Subarray” we have given two arrays Array 1 and Array 2, your task is to find the maximum length of the sub-array that appears in both the arrays. Example Input: [1,2,3,2,1] [3,2,1,4,7] Output: 3 Explanation: Because the maximum length of sub-array is 3 and …

Read moreMaximum Length of Repeated Subarray