#include <bits/stdc++.h>
using namespace std;
char s[1005];
int res[1005];
int main() {
  scanf("%s", &s[1]);
  int n;
  for (n = 1; s[n]; n++)
    ;
  n--;
  char best = s[1];
  for (int i = 1; i <= n; i++) {
    if (s[i] <= best) {
      res[i] = !res[i];
      res[i - 1] = !res[i - 1];
    }
    best = min(best, s[i]);
  }
  for (int i = 1; i <= n; i++) printf("%d ", res[i]);
  return 0;
}
