import java.util.Scanner;
class Main{
Scanner in
= new Scanner
(System.
in); int n, k;
long[] brackets = new long[33];
brackets[0] = 1;
for(int i = 1; i <= 32; ++ i){
brackets[i] = 0;
for(int j = 0; j < i; ++ j){
brackets[i] += brackets[j] * brackets[i - 1 - j];
}
}
n = in.nextInt();
for (int i = 0; i < n; i ++) {
k = in.nextInt();
System.
out.
println(k
% 2 == 0 ? brackets
[k
/ 2] : 0); }
}
}
aW1wb3J0IGphdmEudXRpbC5TY2FubmVyOwoKY2xhc3MgTWFpbnsKCXB1YmxpYyBzdGF0aWMgdm9pZCBtYWluIChTdHJpbmdbXSBhcmdzKSB0aHJvd3MgamF2YS5sYW5nLkV4Y2VwdGlvbnsKCQlTY2FubmVyIGluID0gbmV3IFNjYW5uZXIoU3lzdGVtLmluKTsKCQlpbnQgbiwgazsKCQlsb25nW10gYnJhY2tldHMgPSBuZXcgbG9uZ1szM107CgkJYnJhY2tldHNbMF0gPSAxOwoJCWZvcihpbnQgaSA9IDE7IGkgPD0gMzI7ICsrIGkpewoJCQlicmFja2V0c1tpXSA9IDA7CgkJCWZvcihpbnQgaiA9IDA7IGogPCBpOyArKyBqKXsKCQkJCWJyYWNrZXRzW2ldICs9IGJyYWNrZXRzW2pdICogYnJhY2tldHNbaSAtIDEgLSBqXTsKCQkJfQoJCX0KCQluID0gaW4ubmV4dEludCgpOwogICAgCWZvciAoaW50IGkgPSAwOyBpIDwgbjsgaSArKykgewoJCQlrID0gaW4ubmV4dEludCgpOwoJCQlTeXN0ZW0ub3V0LnByaW50bG4oayAlIDIgPT0gMCA/IGJyYWNrZXRzW2sgLyAyXSA6IDApOwoJCX0KCX0KfQ==