#include <bits/stdc++.h>
using namespace std;
int main() {
  vector<string> v;
  string a;
  cin >> a;
  for (int i = 0; i < a.size(); i++) {
    if (a[i] == '0') v.push_back("O-|-OOOO");
    if (a[i] == '1') v.push_back("O-|O-OOO");
    if (a[i] == '2') v.push_back("O-|OO-OO");
    if (a[i] == '3') v.push_back("O-|OOO-O");
    if (a[i] == '4') v.push_back("O-|OOOO-");
    if (a[i] == '5') v.push_back("-O|-OOOO");
    if (a[i] == '6') v.push_back("-O|O-OOO");
    if (a[i] == '7') v.push_back("-O|OO-OO");
    if (a[i] == '8') v.push_back("-O|OOO-O");
    if (a[i] == '9') v.push_back("-O|OOOO-");
  }
  reverse(v.begin(), v.end());
  for (int i = 0; i < a.size(); i++) {
    cout << v[i] << endl;
  }
}
