공존’s BLOG
/
Database
/
Resources
/
백준_Python
/
7. 백준_Python [10430] 나머지
Search
Share
7. 백준_Python [10430] 나머지
10430번: 나머지
(A+B)%C는 ((A%C) + (B%C))%C 와 같을까?
A
,
B
,
C
=
input
(
)
.
split
(
)
a
=
int
(
A
)
b
=
int
(
B
)
c
=
int
(
C
)
print
(
(
a
+
b
)
%
c
)
print
(
(
(
a
%
c
)
+
(
b
%
c
)
)
%
c
)
print
(
(
a
*
b
)
%
c
)
print
(
(
(
a
%
c
)
*
(
b
%
c
)
)
%
c
)
Python
복사