#include <bits/stdc++.h>
using namespace std;
#define ll long long
int tt, tc;
const int N = 101;
int dp[N][N];
void solve() {
int n;
cin >> n;
for (int i = 1; i <= n; i++)
for (int j = 1; j <= n; j++) {
dp[i][j] = max(dp[i - 1][j], dp[i][j - 1]) + i * j;
}
cout << dp[n][n] << "\n";
}
int main() {
ios::sync_with_stdio(0); cin.tie(0);
tt = 1, tc = 1; cin >> tt;
while (tt--) solve(), tc++;
}
I2luY2x1ZGUgPGJpdHMvc3RkYysrLmg+CnVzaW5nIG5hbWVzcGFjZSBzdGQ7CiNkZWZpbmUgbGwgbG9uZyBsb25nCmludCB0dCwgdGM7Cgpjb25zdCBpbnQgTiA9IDEwMTsKaW50IGRwW05dW05dOwoKdm9pZCBzb2x2ZSgpIHsKICAgIGludCBuOwogICAgY2luID4+IG47CiAgICBmb3IgKGludCBpID0gMTsgaSA8PSBuOyBpKyspCiAgICAgICAgZm9yIChpbnQgaiA9IDE7IGogPD0gbjsgaisrKSB7CiAgICAgICAgICAgIGRwW2ldW2pdID0gbWF4KGRwW2kgLSAxXVtqXSwgZHBbaV1baiAtIDFdKSArIGkgKiBqOwogICAgICAgIH0KICAgIGNvdXQgPDwgZHBbbl1bbl0gPDwgIlxuIjsKfQoKaW50IG1haW4oKSB7CiAgICBpb3M6OnN5bmNfd2l0aF9zdGRpbygwKTsgY2luLnRpZSgwKTsKICAgIHR0ID0gMSwgdGMgPSAxOyBjaW4gPj4gdHQ7CiAgICB3aGlsZSAodHQtLSkgc29sdmUoKSwgdGMrKzsKfQo=