#include <bits/stdc++.h>
using namespace std;
void solve() {
  string s, ans = "";
  cin >> s;
  int len = s.length();
  int i = 0;
  while (i < len) {
    if (s[i] == '.') {
      ans += '0';
      i++;
    } else if (s[i + 1] == '-') {
      ans += '2';
      i += 2;
    } else {
      ans += '1';
      i += 2;
    }
  }
  cout << ans << endl;
}
int main() { solve(); }
