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