You are given S contains only '1' - '9'. Output the length of the longest increasing subsequence. Constraint * 1 ≤ |S| ≤ 27