Problem: <image>


At the request of a friend who started learning abacus, you decided to create a program to display the abacus beads. Create a program that takes a certain number as input and outputs a row of abacus beads. However, the number of digits of the abacus to be displayed is 5 digits, and the arrangement of beads from 0 to 9 is as follows using'*' (half-width asterisk),''(half-width blank), and'=' (half-width equal). It shall be expressed as.

<image>



Input

Multiple test cases are given. Up to 5 digits (integer) are given on one line for each test case.

The number of test cases does not exceed 1024.

Output

Output the abacus bead arrangement for each test case. Insert a blank line between the test cases.

Example

Input

2006
1111


Output

****
    *
=====
 *  *
****
* ***
*****
*****

*****

=====
 ****
*
*****
*****
*****

Solution (in CPP):

Solution:
#define _USE_MATH_DEFINES
#include "bits/stdc++.h"
using namespace std;

//#define int long long
#define DBG 1
#define dump(o) if(DBG){cerr<<#o<<" "<<o<<endl;}
#define dumpc(o) if(DBG){cerr<<#o; for(auto &e:(o))cerr<<" "<<e;cerr<<endl;}
#define rep(i,a,b) for(int i=(a);i<(b);i++)
#define rrep(i,a,b) for(int i=(b)-1;i>=(a);i--)
#define each(it,c) for(auto it=(c).begin();it!=(c).end();it++)
#define all(c) c.begin(),c.end()
const int INF = sizeof(int) == sizeof(long long) ? 0x3f3f3f3f3f3f3f3fLL : 0x3f3f3f3f;
const int MOD = (int)(1e9 + 7);
const double EPS = 1e-10;

signed main() {
	string s; int cnt(0);
	while (cin >> s) {
		while (s.size() < 5)s = "0" + s;
		vector<string>v(8, "     ");
		v[2] = "=====";
		rep(i, 0, 5) {
			rep(j, 0, 8) {
				switch (j)
				{
				case 0:
					if ('0' <= s[i] && s[i] <= '4')v[j][i] = '*';
					break;
				case 1:
					if ('5' <= s[i] && s[i] <= '9')v[j][i] = '*';
					break;
				case 2:
					break;
				case 3:
					if (s[i] != '0'&&s[i] != '5')v[j][i] = '*';
					break;
				case 4:
					if (s[i] != '1'&&s[i] != '6')v[j][i] = '*';
					break;
				case 5:
					if (s[i] != '2'&&s[i] != '7')v[j][i] = '*';
					break;
				case 6:
					if (s[i] != '3'&&s[i] != '8')v[j][i] = '*';
					break;
				case 7:
					if (s[i] != '4'&&s[i] != '9')v[j][i] = '*';
					break;
				default:
					break;
				}
			}
		}
		if (cnt++)cout << endl;
		rep(i, 0, 8)cout << v[i] << endl;
	}
	return 0;
}