import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Solution { static int maxdp=0; static long longestSequence(long[] a) { long out=0; long []dp=new long[maxdp+1]; dp[0]=0; dp[1]=1; for(int i=2;i