#include #define be(v) (v).begin(),(v).end() #define pb(q) push_back(q) typedef long long ll; using namespace std; const ll mod=1000000007, INF=(1LL<<60); #define doublecout(a) cout<> t; while(t--){ ll n; cin >> n ; n--; cout << n * n << endl; } return 0; }