Longest common subsequence http://en.wikipedia.org/wiki/Longest_common_subsequence_problem Generalizations: up to N errors. https://www.hackerrank.com/challenges/substring-diff Implementations longest_common_subsequence.cpp