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