Print Shortest Common Supersequence Leetcode Javascript