#include #include #include #include #include #include #include #include #include #include using namespace std; struct aaa{aaa(){cin.tie(nullptr); ios::sync_with_stdio(false); cout<ostream &operator<<(ostream &o,const vector&v){o<<"{";for(int i=0;i<(int)v.size();i++)o<<(i>0?", ":"")<bool chmax(T a,T& b) {if (b> n; int64 n_max = n; int cnt = 0; while(n != 1) { if (n%2) n = 3*n+1; else n /= 2; n_max = max(n_max, n); cnt++; } cout << cnt << endl << n_max; }