Submission

Status:

PPPPPPPPPP

Subtask/Task Score:

100/100

Score: 100

User: spammer_destroyer

Problemset: ลูกเต๋า (2566)

Language: cpp

Time: 0.002 second

Submitted On: 2025-10-12 12:52:52

//c1_bkk66_3
#include <iostream>
#include <string>
#include <vector>
using namespace std;
vector<string> face(int n) {
  vector<string> str(3);
  switch(n) {
case 1:
  str[0]="   ";
  str[1]=" * ";
  str[2]="   ";return str;
case 2:
  str[0]=" * ";
  str[1]="   ";
  str[2]=" * ";return str;
case 3:
  str[0]="*  ";
  str[1]=" * ";
  str[2]="  *";return str;
case 4:
  str[0]="* *";
  str[1]="   ";
  str[2]="* *";return str;
case 5:
  str[0]="* *";
  str[1]=" * ";
  str[2]="* *";return str;
case 6:
  str[0]="* *";
  str[1]="* *";
  str[2]="* *";return str;
default:
  str[0]="   ";
  str[1]="   ";
  str[2]="___";return str;
  }
}

int main() {
  int n,i;
  cin >> n;
  int dice1=n/100;
  int dice2=(n/10)%10;
  int dice3=n%10;
  vector<string> d1=face(dice1);
  vector<string> d2=face(dice2);
  vector<string> d3=face(dice3);
  for(i=0;i<3;i++) {
    cout << d1[i] << " " << d2[i] << " " << d3[i] << "\n";
  }
  return 0;
}