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