#include <bits/stdc++.h>
using namespace std;
const int N = 210;
int last1[N][N][4][4];
int last2[N][N][4][4];
void dfs(int score1, int score2, int num1, int num2) {
  if (num1 == 3 || num2 == 3) return;
  int win_score = 25;
  if (num1 + num2 == 4) win_score = 15;
  for (int i = 0; i <= win_score - 2; i++) {
    int n_score1 = score1 + i;
    int n_score2 = score2 + win_score;
    int n_num1 = num1;
    int n_num2 = num2 + 1;
    if (n_score1 > 200 || n_score2 > 200) {
      break;
    }
    if (last1[n_score1][n_score2][n_num1][n_num2] != -1) continue;
    last1[n_score1][n_score2][n_num1][n_num2] = i;
    last2[n_score1][n_score2][n_num1][n_num2] = win_score;
    dfs(n_score1, n_score2, n_num1, n_num2);
  }
  for (int i = 0; i <= win_score - 2; i++) {
    int n_score1 = score1 + win_score;
    int n_score2 = score2 + i;
    int n_num1 = num1 + 1;
    int n_num2 = num2;
    if (n_score1 > 200 || n_score2 > 200) {
      break;
    }
    if (last1[n_score1][n_score2][n_num1][n_num2] != -1) continue;
    last1[n_score1][n_score2][n_num1][n_num2] = win_score;
    last2[n_score1][n_score2][n_num1][n_num2] = i;
    dfs(n_score1, n_score2, n_num1, n_num2);
  }
  for (int i = win_score + 1; i < N; i++) {
    int n_score1 = score1 + i;
    int n_score2 = score2 + i - 2;
    int n_num1 = num1 + 1;
    int n_num2 = num2;
    if (n_score1 > 200 || n_score2 > 200) {
      break;
    }
    if (last1[n_score1][n_score2][n_num1][n_num2] != -1) continue;
    last1[n_score1][n_score2][n_num1][n_num2] = i;
    last2[n_score1][n_score2][n_num1][n_num2] = i - 2;
    dfs(n_score1, n_score2, n_num1, n_num2);
  }
  for (int i = win_score + 1; i < N; i++) {
    int n_score1 = score1 + i - 2;
    int n_score2 = score2 + i;
    int n_num1 = num1;
    int n_num2 = num2 + 1;
    if (n_score1 > 200 || n_score2 > 200) {
      break;
    }
    if (last1[n_score1][n_score2][n_num1][n_num2] != -1) continue;
    last1[n_score1][n_score2][n_num1][n_num2] = i - 2;
    last2[n_score1][n_score2][n_num1][n_num2] = i;
    dfs(n_score1, n_score2, n_num1, n_num2);
  }
}
int main() {
  memset(last1, -1, sizeof(last1));
  memset(last2, -1, sizeof(last2));
  dfs(0, 0, 0, 0);
  int m;
  scanf("%d", &m);
  for (int i = 0; i < m; i++) {
    int a, b;
    scanf("%d%d", &a, &b);
    int flag = 0;
    int result[5][2];
    int p, q;
    int num = 0;
    int ta = a, tb = b;
    for (int i = 0; i <= 3; i++) {
      for (int j = 0; j <= 3; j++) {
        if ((i == 3 || j == 3) && last1[ta][tb][i][j] != -1) {
          if (flag && i - j < p - q) continue;
          a = ta, b = tb;
          flag = 1;
          p = i, q = j;
          num = 0;
          while (a + b) {
            result[num][0] = last1[a][b][p][q];
            result[num][1] = last2[a][b][p][q];
            a -= result[num][0];
            b -= result[num][1];
            if (result[num][0] > result[num][1]) {
              p--;
            } else {
              q--;
            }
            num++;
          }
          p = i, q = j;
        }
      }
    }
    if (flag) {
      printf("%d:%d\n", p, q);
      for (int i = num - 1; i >= 0; i--) {
        printf("%d:%d", result[i][0], result[i][1]);
        if (i)
          printf(" ");
        else
          printf("\n");
      }
    } else {
      puts("Impossible");
    }
  }
}
