#include <bits/stdc++.h>
using namespace std;
int ans[101];
int main() {
  int t;
  scanf("%d", &t);
  while (t--) {
    int n, cnt = 0;
    scanf("%d", &n);
    for (int i = 1; i <= n; i *= 2) {
      ans[++cnt] = i;
      n -= i;
    }
    if (n > 0) {
      ans[++cnt] = n;
      sort(ans + 1, ans + cnt + 1);
    }
    printf("%d\n", cnt - 1);
    for (int i = 2; i <= cnt; i++) printf("%d ", ans[i] - ans[i - 1]);
    printf("\n");
  }
  return 0;
}
