#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  string str;
  cin >> str;
  n = str.size();
  for (int j = 0; j < n; j++) {
    if (str[j] == '.')
      cout << 0;
    else if ((str[j] == '-') && (str[j + 1] == '.')) {
      cout << 1;
      j++;
    } else if ((str[j] == '-') && (str[j + 1] == '-')) {
      cout << 2;
      j++;
    }
  }
  return 0;
}
