add 中国剩余定理.
This commit is contained in:
parent
be353533a7
commit
2aa12fbb6e
@ -70,8 +70,8 @@ def lcm(a, b):
|
|||||||
ans = 2022040920220409
|
ans = 2022040920220409
|
||||||
check(ans)
|
check(ans)
|
||||||
|
|
||||||
ans = 1
|
# 中国剩余定理
|
||||||
product = 1
|
ans = product = 1
|
||||||
for num, mod in nums:
|
for num, mod in nums:
|
||||||
while ans % num != mod:
|
while ans % num != mod:
|
||||||
ans += product
|
ans += product
|
||||||
|
Loading…
Reference in New Issue
Block a user