#include <bits/stdc++.h>
const long long mod = 1e9 + 7;
const long long mod6 = 1e6;
using namespace std;
int main() {
  int cnt = 0;
  string s;
  cin >> s;
  for (int i = s.size() - 1; i >= 0; i--) {
    if (s[i] == '0')
      cnt++;
    else if (cnt)
      cnt--;
    else
      s[i] = '0';
  }
  cout << s << "\n";
  return 0;
}
