func_code_string: #include <bits/stdc++.h>   #pragma comment(linker,  /STACK:33554432 )   using namespace std;   const double PI = 2 * acos(0.0);   const double EPS = 1e-8;   const int INF = (1 << 30) - 1;   int n;   string s;   vector<int> p;   set<int> ans;   void add01(char c1, char c2, int a, int b) {     for (int i = 0; i < a; ++i) s[p[i]] = c1;     for (int i = 0; i < b; ++i) s[p[a + i]] = c2;   }   int getans() {     int i = n - 1;     while (s[i] !=  0 ) --i;     int j = n - 1;     while (s[j] !=  1 ) --j;     if (i < j)       return 1;     else       return 2;   }   void printbin(int n) { cout << n / 2 << n % 2 << endl; }   int main() {     cin >> s;     if ((int)((s).size()) % 2 == 1) s =  0  + s;     n = (int)((s).size());     int cnt = 0, cnt1 = 0, cnt0 = 0;     for (int i = 0; i < n; ++i)       if (s[i] ==  ? ) {         ++cnt;         p.push_back(i);       } else if (s[i] ==  1 )         ++cnt1;       else if (s[i] ==  0 )         ++cnt0;     if (cnt0 >= cnt1 + cnt + 2) {       cout <<  00 ;       return 0;     }     if (cnt1 >= cnt0 + cnt + 2) {       cout <<  11 ;       return 0;     }     if (cnt0 + cnt >= cnt1 + 2) ans.insert(0);     if (cnt1 + cnt >= cnt0 + 2) ans.insert(3);     add01( 0 ,  1 , n / 2 - cnt0, n / 2 - cnt1);     ans.insert(getans());     add01( 1 ,  0 , n / 2 - cnt1, n / 2 - cnt0);     ans.insert(getans());     for (set<int>::iterator i = ans.begin(); i != ans.end(); ++i) printbin(*i);     return 0;   };   