#include <bits/stdc++.h>   using namespace std;   const int MAXN = 100010;   char str[MAXN];   int k1, k0, k2;   int main() {     scanf( %s , str);     int n = strlen(str);     k1 = k2 = k0 = 0;     for (int i = 0; i < n; i++) {       if (str[i] ==  0 ) k0++;       if (str[i] ==  1 ) k1++;       if (str[i] ==  ? ) k2++;     }     if (k2 + k0 >= (n - 2) / 2 + 2) cout <<  00  << endl;     if (k0 + k2 > (n - 2) / 2 && k1 + k2 > (n - 1) / 2) {       if (str[n - 1] ==  1  || (str[n - 1] ==  ?  && k0 + k2 - 1 > (n - 2) / 2))         cout <<  01  << endl;       if (str[n - 1] ==  0  || (str[n - 1] ==  ?  && k1 + k2 - 1 > (n - 1) / 2))         cout <<  10  << endl;     }     if (k2 + k1 >= (n - 1) / 2 + 2) cout <<  11  << endl;     return 0;   }   