#include <bits/stdc++.h>
using namespace std;
void solve();
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  string s;
  cin >> s;
  long long n = s.length();
  for (long long i = 0; i < n; ++i) {
    if (s[i] == '.')
      cout << "0";
    else {
      if (s[i + 1] == '-')
        cout << "2";
      else
        cout << "1";
      i++;
    }
  }
  cout << "\n";
  return 0;
}
