#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  int cnt = 0, l = s.size();
  for (int i = l - 1; i >= 0; i--)
    if (s[i] == '0')
      cnt++;
    else if (s[i] == '1') {
      if (cnt)
        cnt--;
      else
        s[i] = '0';
    }
  cout << s;
}
