#include <bits/stdc++.h>
using namespace std;
const long long mod = 998244353;
void ingraph(vector<long long> graph[], long long m) {
  long long x, y;
  for (long long i = 0; i < m; i++) {
    cin >> x >> y;
    x--, y--;
    graph[x].push_back(y);
    graph[y].push_back(x);
  }
}
long long gcd(long long a, long long b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
long long lcm(long long a, long long b) { return a * b / gcd(a, b); }
long long modmulti(long long a, long long b) {
  return ((a % mod) * 1ll * (b % mod)) % mod;
}
long long modadd(long long a, long long b) {
  long long asdfgh = ((a % mod) + (b % mod) + mod + mod) % mod;
  asdfgh = (asdfgh + mod) % mod;
  return asdfgh;
}
long long modpower(long long a, long long n) {
  if (n == 0) return 1;
  if (n == 1) return a % mod;
  long long b = modpower(a, n / 2);
  b = modmulti(b, b);
  if (n % 2 == 0) return b;
  return modmulti(a, b);
}
long long modinv(long long a) { return modpower(a, mod - 2); }
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(NULL);
  long long t;
  cin >> t;
  while (t--) {
    long long n;
    cin >> n;
    long long sum = 0;
    vector<long long> vec;
    for (long long i = 1; i <= n; i = i * 2) {
      vec.push_back(i);
      n = n - i;
    }
    if (n > 0) {
      vec.push_back(n);
    }
    sort(vec.begin(), vec.end());
    cout << (long long)(vec).size() - 1 << '\n';
    for (long long i = 1; i < (long long)(vec).size(); i++)
      cout << vec[i] - vec[i - 1] << " ";
    cout << '\n';
  }
  return 0;
}
