Longest Common Subsequence
Given two strings text1 and text2, return the length of their longest common subsequence. If there is no common subsequence, return 0.
Longest Common Subsequence

Given two strings text1 and text2, return the length of their longest common subsequence. If there is no common subsequence, return 0.

Example 1:
Input: {"text1":"abcde","text2":"ace"}
Output: 3
Input
arr ={"text1":"abcde","text2":"ace"}

Init DP table with 0s

a

c

e

0

0

0

0

a

0

0

0

0

b

0

0

0

0

c

0

0

0

0

d

0

0

0

0

e

0

0

0

0

Variables
No variables to display
DepthFunction Call
Stack empty
0/31