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