#include #include #include #include #include using namespace std; #define Int register int void read (int &x) { x = 0;char c = getchar();int f = 1; while (c < '0' || c > '9') {if (c == '-') f = -f;c = getchar();} while (c >= '0' && c <= '9') {x = (x << 3) + (x << 1) + c - '0';c = getchar();} x *= f;return ; } void write (int x) { if (x < 0){x = -x;putchar ('-');} if (x > 9) write (x / 10); putchar (x % 10 + '0'); } signed main() { int times; read (times); while (times --) { int n; read (n); if (n % 2) write (n - 1),putchar ('\n'); else write (n + 1),putchar ('\n'); } }