#include <bits/stdc++.h>
using namespace std;
long long read() {
  long long x = 0, f = 1;
  char ch = getchar();
  while (ch - '0' < 0 || ch - '0' > 9) {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while (ch - '0' >= 0 && ch - '0' <= 9) {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  return x * f;
}
int Q;
long long st, en, m;
long long a[55];
long long cha[55];
int main() {
  Q = read();
  while (Q--) {
    st = read();
    en = read();
    m = read();
    if (st == en) {
      printf("1 %lld\n", st);
      continue;
    }
    a[1] = st;
    long long sum = st;
    int len = 1;
    while (true) {
      if (sum + 1 > en) break;
      len++;
      a[len] = sum + 1;
      sum += a[len];
    }
    for (int i = 1; i < len; i++) cha[i] = 1;
    long long tmp = en - a[len];
    for (int i = len - 3; i >= 0; i--) {
      long long k = min(tmp / (1ll << i), m - 1);
      cha[len - i - 2] += k;
      tmp -= k * (1ll << i);
      if (tmp == 0) break;
    }
    if (tmp <= m - 1)
      cha[len - 1] += tmp;
    else {
      puts("-1");
      continue;
    }
    printf("%d ", len);
    sum = st;
    printf("%lld ", st);
    for (int i = 1; i < len; i++) {
      printf("%lld ", sum + cha[i]);
      sum += sum + cha[i];
    }
    puts("");
  }
  return 0;
}
