Rohyoohyun / C

0 stars 0 forks source link

3003 킹, 퀸, 룩, 비숍, 나이트, 폰 #28

Open Rohyoohyun opened 3 months ago

Rohyoohyun commented 3 months ago
#include <stdio.h>
int main(){
    int chess[6] = {1, 1, 2, 2, 2, 8};
    int answer[6] = {0};

    for(int i=0; i<6; i++)
        scanf("%d", &answer[i]);

    int re[6] = {0};
    for(int i=0; i<6; i++){
        re[i] = chess[i] - answer[i];
        printf("%d ", re[i]);
    }

    return 0;
}