#include <bits/stdc++.h>
using namespace std;
char s[2020], ss[2020];
int a[2020];
int main() {
  cin >> s;
  strcpy(ss, s);
  int n = strlen(s);
  while (1) {
    int k = 0, f = 0;
    for (int i = 0; i < n; i++)
      if (s[i] != '*') a[k++] = i;
    for (int i = 0; i < k - 1; i++) {
      if (s[a[i]] == '1' and s[a[i + 1]] == '0') {
        s[a[i]] = '*', s[a[i + 1]] = '*';
        i++;
        f = 1;
      }
    }
    if (!f) break;
  }
  for (int i = 0; i < n; i++) {
    if (s[i] != '*') ss[i] = '0';
    cout << ss[i];
  }
  return 0;
}
