Longest Common Subsequence | DP-4 - GeeksforGeeks
A Computer Science portal for geeks. It contains well written, well thought and well explained computer science and programming articles, quizzes and practice/competitive programming/company interview Questions.
Longest Common Subsequence (LCS) - GeeksforGeeks Courses Tutorials Interview Prep DSA Tutorial Interview Questions Quizzes Must Do Advanced DSA System Design Aptitude Puzzles Interview Corner DSA Python Longest Common Subsequence (LCS) Last Updated : 13 Apr, 2026 Given two strings, s1 and s2 , find the length of the Longest Common Subsequence. If there is no common subsequence , return 0 . A subsequence is a string generated from the original string by deleting 0 or more characters, without changing the relative order of the remaining characters. For example, subsequences of "ABC" are "", "A",
related reading
- Levenshtein distance - Wikipediaen.wikipedia.org
- Introduction to Dynamic Programming - Algorithms for Competitive Programmingcp-algorithms.com
- HackerRank - Online Coding Tests and Technical Interviewshackerrank.com
- Competitive Programmer's Handbookcses.fi
- Tabulation vs. Memoization | Baeldung on Computer Sciencebaeldung.com
- LeetCode-Solutions/0001-1000.md at master · Holychung/LeetCode-Solutionsgithub.com
- Dynamic time warping - Wikipediaen.wikipedia.org
- Notes - Suffix Treevisualgo.net
- Euclidean algorithm for computing the greatest common divisor - Algorithms for Competitive Programmingcp-algorithms.com
- The Myers diff algorithm: part 1 – The If Worksblog.jcoglan.com
- Beating Myers algorithm on large diffsjzhao.xyz
- Colfcolf.dev