#include <bits/stdc++.h>
using namespace std;
const int N = 100004;
char s[N];
int sum[N][4];
char t[N];
vector<int> cntZero, pos;
int main() {
  int n;
  scanf("%s", s + 1);
  n = strlen(s + 1);
  int i, j;
  int cntz = 0, cnto = 0, cntt = 0;
  for (i = 1; i <= n; i++) {
    if (s[i] == '2') {
      pos.push_back(i);
      cntt++;
    } else if (s[i] == '1')
      cnto++;
    else
      cntz++;
    for (j = 0; j < 3; j++)
      sum[i][j] = sum[i - 1][j] + (((s[i] - '0') == j) ? 1 : 0);
  }
  sum[n + 1][0] = sum[n][0];
  sum[n + 1][1] = sum[n][1];
  sum[n + 1][2] = sum[n][2];
  pos.push_back(n + 1);
  j = n;
  int val = 0;
  for (i = pos.size() - 1; i > 0; i--) {
    int cnt = sum[pos[i]][0] - sum[pos[i - 1]][0];
    val = val + cnt;
    while (cnt > 0) {
      t[j] = '0';
      cnt--;
      j--;
    }
    t[j] = '2';
    j--;
  }
  for (i = 1; i <= cntz - val; i++) t[i] = '0';
  for (i = cntz - val + 1; i <= j; i++) t[i] = '1';
  printf("%s\n", t + 1);
  return 0;
}
