import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Solution { static long[] lookup = new long[10000]; static long longestSequence(long[] a) { lookup[0] = 0; lookup[1] = 1; lookup[2] = 3; long sum = 0; for(int i=0;i