Submission
Status:
PPPP---PPP
Subtask/Task Score:
70/100
Score: 70
User: boygunner
Problemset: ลูกเต๋า (2566)
Language: cpp
Time: 0.004 second
Submitted On: 2026-10-03 21:36:35
#include<bits/stdc++.h>
using namespace std;
int main(){
string dice[6][3];
int num,unit,ten,hund;
dice[0][0]=" ";
dice[0][1]=" * ";
dice[0][2]=" ";
dice[1][0]=" * ";
dice[1][1]=" ";
dice[1][2]=" * ";
dice[2][0]="* ";
dice[2][1]=" * ";
dice[2][2]=" *";
dice[3][0]="* *";
dice[3][1]=" ";
dice[3][2]="* *";
dice[4][0]="* *";
dice[4][1]=" * ";
dice[4][2]="* *";
dice[5][0]="* *";
dice[5][1]="* *";
dice[5][2]="* *";
cin>>num;
unit=num%10;
num=num/10;
ten=num%10;
num=num/10;
hund=num;
for(int r=0;r<=2;r++){
if(hund>=1 && hund<=6) cout<<dice[hund-1][r]<<' ';
else cout<<"___";
if(ten>=1 && ten<=6) cout<<dice[ten-1][r]<<' ';
else cout<<"___";
if(unit>=1 && unit<=6) cout<<dice[unit-1][r]<<endl;
else cout<<"___"<<endl;
}
}