#include <bits/stdc++.h>
using namespace std;
int main() {
  bool t = 0;
  long long x;
  cin >> x;
  while (t == 0 || x != 0) {
    t = 1;
    if (x % 10 >= 5)
      cout << "-O|";
    else
      cout << "O-|";
    if ((x % 10 - 5 * (x % 10 >= 5)) == 1)
      cout << "O-OOO" << endl;
    else if ((x % 10 - 5 * (x % 10 >= 5)) == 2)
      cout << "OO-OO" << endl;
    else if ((x % 10 - 5 * (x % 10 >= 5)) == 3)
      cout << "OOO-O" << endl;
    else if ((x % 10 - 5 * (x % 10 >= 5)) == 4)
      cout << "OOOO-" << endl;
    else if ((x % 10 - 5 * (x % 10 >= 5)) == 0)
      cout << "-OOOO" << endl;
    x /= 10;
  }
  return 0;
}
