#include using namespace std; bool flag[1000005]; vector prime; long factorize(long a) { long total = a; //cout< 1 && idx < prime.size() && prime[idx] * prime[idx] <= a) { while (a % prime[idx] == 0) { a /= prime[idx]; //cout< 1) { total += 1; //cout<<1< a) { long total = 0; for (int i=0;i> n; vector a(n); for(int a_i = 0; a_i < n; a_i++){ cin >> a[a_i]; } long result = longestSequence(a); cout << result << endl; return 0; }