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