#include <bits/stdc++.h>
using namespace std;
char s[100005];
signed main() {
  cin >> (s + 1);
  long long l = strlen(s + 1);
  long long cnt1 = 0, cnt0 = 0;
  for (long long i = l; i >= 0; i--) {
    if (s[i] == '0') {
      cnt0++;
    } else {
      cnt1++;
      if (cnt1 > cnt0) {
        cnt1--;
        s[i] = '0';
      }
    }
  }
  cout << (s + 1);
  return 0;
}
