Longest Increasing Subsequence.c