본문 바로가기
PROGRAMMING CODE/C

[BAEKJOON] No.10430 C언어

by daye_ 2021. 10. 18.

나머지

 

#include <stdio.h>

int main(int argc, const char * argv[]) {
    int a=0,b=0,c=0;
    scanf("%d %d %d",&a,&b,&c);
    printf("%d\n",(a+b)%c);
    printf("%d\n",((a%c) + (b%c))%c);
    printf("%d\n",(a*b)%c);
    printf("%d\n",((a%c) * (b%c))%c);
    return 0;
}

'PROGRAMMING CODE > C' 카테고리의 다른 글

[BAEKJOON] No.10871 C언어  (0) 2021.10.18
[BAEKJOON] No.10869 C언어  (0) 2021.10.18
[BAEKJOON] No.10172 C언어  (0) 2021.10.18
[BAEKJOON] No.2164 C언어  (0) 2021.10.18
[BAEKJOON] No.10171 C언어  (0) 2021.10.15