- 풀이
#include<iostream>
int main() {
int A,B;
scanf("%d %d", &A, &B);
int a, b, c;
a = A * (B % 10);
b = (A * ((B % 100) - (B % 10)))/10;
c = A * (B / 100);
printf("%d\n", a);
printf("%d\n", b);
printf("%d\n", c);
printf("%d\n", a + (b * 10) + (c * 100));
}
'코딩테스트 > programming_C++' 카테고리의 다른 글
baekjoon #10818_최소, 최대_c++ (0) | 2021.10.24 |
---|---|
baekjoon #10951_A+B - 4_c++ (0) | 2021.10.24 |
baekjoon #2439_별 찍기 - 2_c++ (0) | 2021.10.24 |
baekjoon #15552_빠른 A+B_c++ (0) | 2021.10.24 |
baekjoon #1008_A/B_c++ (0) | 2021.10.24 |