#include<vector>
#include<algorithm>
#include<iostream>
#include<cstring>
using namespace std;
const int N = 6e5 + 10;
int cnt = 1;
int e[N];
int main()
{
string s;
cin >> s;
string t = s;
s += "0000";
int l1 = t.size(), l2 = s.size();
int c = 0;
string res = "";
for (int i = t.size() - 1, j = s.size() - 1; j >= 0 || i >= 0; i --, j --)
{
if(j >= 0)
c += s[j] - ‘0‘;
if(i >= 0)
c += t[i] - ‘0‘;
res += c % 2 + ‘0‘;
c /= 2;
}
if(c)
res += ‘1‘;
reverse(res.begin(), res.end());
cout << res << endl;
}
//3 9 -5 8 -6 6 2 -9 -1 -4
高精度二进制加法