longest increasing sequence

DP using bottom up.

the statement function is:

when a[j] > a[i]
    l(j) = max(l(i)) + 1

and the final result should be:

    max(l(j))
the sequence should be reversed

I save the previous index of each l(j)
so that we can backtrace where we come from.