func_code_string: #include <bits/stdc++.h>   using namespace std;   template <class T>   void read(T& num) {     char CH;     bool F = false;     for (CH = getchar(); CH <  0  || CH >  9 ; F = CH ==  - , CH = getchar())       ;     for (num = 0; CH >=  0  && CH <=  9 ;          num = num * 10 + CH -  0 , CH = getchar())       ;     F && (num = -num);   }   int stk[70], tp;   template <class T>   inline void print(T p) {     if (!p) {       puts( 0 );       return;     }     while (p) stk[++tp] = p % 10, p /= 10;     while (tp) putchar(stk[tp--] +  0 );     putchar(  n );   }   const long long mod = 1e9 + 7;   const double PI = acos(-1.0);   const int inf = 1e9;   const int N = 1e5 + 10;   const int maxn = 1e3 + 20;   const double eps = 1e-12;   int check(int x) {     int l = 1, r = 1000005;     if (x == 0) return 0;     while (l <= r) {       int mid = (l + r) >> 1;       if ((long long)mid * (mid - 1) < (long long)2 * x)         l = mid + 1;       else         r = mid - 1;     }     return l;   }   int main() {     int a, b, c, d;     read(a);     read(b);     read(c);     read(d);     int x = check(a), y = check(d);     if (x == 0 && (b || c)) x = 1;     if (y == 0 && (b || c)) y = 1;     if ((long long)x * (x - 1) != (long long)2 * a ||         (long long)y * (y - 1) != (long long)2 * d ||         (long long)x * y != (long long)b + c)       cout <<  Impossible n ;     else {       if (x == 0 && y == 0)         printf( 0 );       else if (x == 0) {         for (int i = 1; i <= y; i++) printf( 1 );       } else if (y == 0) {         for (int i = 1; i <= x; i++) printf( 0 );       } else {         int t = b / y, f = y - b % y;         for (int i = 1; i <= t; i++) printf( 0 ), x--;         for (int i = 1; i <= f; i++) printf( 1 ), y--;         if (x > 0) {           printf( 0 );           x--;         }         for (int i = 1; i <= y; i++) printf( 1 );         for (int i = 1; i <= x; i++) printf( 0 );       }     }     return 0;   }   