#include <bits/stdc++.h>   #pragma GCC optimize( Ofast )   using namespace std;   const long long infl = 0x3f3f3f3f3f3f3f3fLL;   const long long infi = 0x3f3f3f3f;   mt19937_64 mt(chrono::steady_clock::now().time_since_epoch().count());   const long long mod = 1e9 + 7;   const long long N = 1e6 + 5;   void solve() {     long long m;     cin >> m;     cout << (m / 4 + 1) % mod * ((m / 2 - m / 4 + 1) % mod + mod) % mod <<   n ;   }   signed main() {     ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);     cout << fixed << setprecision(15);     long long t = 1;     cin >> t;     while (t--) solve();     return 0;   }   long long powm(long long a, long long b) {     long long res = 1;     while (b) {       if (b & 1) res = (res * a) % mod;       a = (a * a) % mod;       b >>= 1;     }     return res;   }   long long divide(long long a, long long b) {     return (a % mod) * powm(b, mod - 2) % mod;   }   long long gcd(long long a, long long b) { return b ? gcd(b, a % b) : a; }   