import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Solution { static long longestSequence(long[] a) { int k=0; long j; long sum=0; long val=0; long fact[]=new long[50]; long div[]=new long[50]; for(int i=0;i=2){ if(val%j==0){ fact[k]=j; } j--; k++; } for(int x=0;x