#include <bits/stdc++.h>
#pragma comment(linker, "/STACK:102400000,102400000")
using namespace std;
const int M = 1e6 + 5, mod = 1e9 + 7, INF = 0x3f3f3f3f;
char s[M];
int A[M];
int sum[M];
int main() {
  int a00, a01, a10, a11;
  scanf("%d%d%d%d", &a00, &a01, &a10, &a11);
  int num0 = -1, num1 = -1;
  for (int j = 0; j * (j - 1) / 2 <= a00; j++) {
    if (j * (j - 1) / 2 == a00) {
      num0 = j;
    }
  }
  for (int j = 0; j * (j - 1) / 2 <= a11; j++) {
    if (j * (j - 1) / 2 == a11) {
      num1 = j;
    }
  }
  if (!a00 && !a01 && !a10 && !a11)
    printf("1\n");
  else if (a00 && !a01 && !a10 && !a11) {
    if (num0 == -1) {
      printf("Impossible\n");
      return 0;
    }
    while (num0) {
      num0--;
      printf("0");
    }
  } else if (!a00 && !a01 && !a10 && a11) {
    if (num1 == -1) {
      printf("Impossible\n");
      return 0;
    }
    while (num1) {
      num1--;
      printf("1");
    }
  } else if (num0 == -1 || num1 == -1)
    printf("Impossible\n");
  else {
    if (a01 + a10 != num0 * num1)
      printf("Impossible\n");
    else {
      int t = a01;
      for (int j = 1; j <= num0; j++) {
        if (t >= num1) {
          A[j] = num1;
          t -= num1;
        } else {
          A[j] = t;
          t = 0;
        }
      }
      if (t) {
        printf("Impossible\n");
      } else {
        for (int j = 1; j <= num0; j++) {
          sum[A[j]]++;
        }
        for (int j = num1; j >= 1; j--) {
          while (sum[j]) {
            printf("0");
            sum[j]--;
          }
          printf("1");
        }
        while (sum[0]) {
          printf("0");
          sum[0]--;
        }
        printf("\n");
      }
    }
  }
  return 0;
}
