Submission

Status:

PPPPPPPPPPPPPPPPPPPP

Subtask/Task Score:

100/100

Score: 100

User: black_guy001

Problemset: Abacus

Language: cpp

Time: 0.002 second

Submitted On: 2026-03-19 14:14:49

#include <bits/stdc++.h>
using namespace std;

int main(){
    string s;
    cin >> s;

    while (s.length()<8) s = '0'+s;

    vector<int> x;
    for (char c : s){
        x.push_back(c-'0');
    }
    cout << "* * * * * * * * " << endl;
    for(int i=0;i<2;i++){
        for(int j=0;j<8;j++){
            int d = x[j];
            if((i==0 && d<5) || (i==1 && d>=5)) cout << "* ";
            else cout << "  ";
        }
        cout << endl;
    }
    cout << "-----------------" << endl;
    for(int i=0;i<5;i++){
        for(int j=0;j<8;j++){
            if(i==0&&(x[j]%5>0)) cout << "* ";
            else if (i==0&&(x[j]%5==0)) cout << "  ";
            else if ((x[j]%5)==i) cout << "  ";
            else cout << "* ";
        }
        cout << endl;
    }
    cout << "* * * * * * * * " << endl;
}