#include using namespace std; #define REP(i,a,n) for(int i=(a); i<(int)(n); i++) #define rep(i,n) REP(i,0,n) #define FOR(it,c) for(__typeof((c).begin()) it=(c).begin(); it!=(c).end(); ++it) #define ALLOF(c) (c).begin(), (c).end() typedef long long ll; typedef unsigned long long ull; const static ll INF = (ll)(1e15); bool isKadomatsu(int A, int B, int C){ map m; m[A] = 1; m[B] = 1; m[C] = 1; if(m.size() != 3) return false; vector v{A,B,C}; sort(ALLOF(v)); return (v[1]==A || v[1]==C); } ll check(int A, int B, int C, int tA, int tB, int tC){ //if(A cand; for(int i=-2; i<=2; i++) if(A+i>0) cand[A+i] = 1; for(int i=-2; i<=2; i++) if(B+i>0) cand[B+i] = 1; for(int i=-2; i<=2; i++) if(C+i>0) cand[C+i] = 1; vector v; FOR(it,cand) v.push_back(it->first); ll ret = INF; rep(i,v.size()){ if(A> T; rep(t,T){ int A, B, C; cin >> A >> B >> C; cout << solve(A, B, C) << endl; } return 0; }