Longest Shared Subsequence - Coding problem | OneNoughtOne