#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  vector<int> v;
  cin >> s;
  int l = s.size(), a, b, c;
  for (int i = 0; i < l;) {
    if (s[i] == '-' && s[i + 1] == '.') {
      cout << 1;
      i = i + 2;
      v.push_back(1);
    } else if (s[i] == '-' && s[i + 1] == '-') {
      cout << 2;
      i = i + 2;
      v.push_back(2);
    } else if (s[i] == '.') {
      cout << 0;
      i++;
      v.push_back(0);
    }
  }
  int p = v.size();
}
