#include <bits/stdc++.h>
using namespace std;
void TheSolution(istream& input, ostream& output) {
  int n;
  input >> n;
  stringstream ss;
  ss << n;
  string S = ss.str();
  for (int i = 0; i < S.length(); ++i) {
    int d = S[S.length() - i - 1] - '0';
    if (d < 5)
      output << "O-|";
    else
      output << "-O|";
    d %= 5;
    for (int i = 0; i < 5; i++) {
      if (i == d)
        output << "-";
      else
        output << "O";
    }
    output << "\n";
  }
}
int main() {
  ios_base::sync_with_stdio(false);
  TheSolution(cin, cout);
  return 0;
}
