結果
問題 |
No.2558 中国剰余定理
|
ユーザー |
|
提出日時 | 2023-12-02 15:21:07 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 77 ms / 2,000 ms |
コード長 | 576 bytes |
コンパイル時間 | 304 ms |
コンパイル使用メモリ | 82,176 KB |
実行使用メモリ | 60,416 KB |
最終ジャッジ日時 | 2024-09-26 18:31:25 |
合計ジャッジ時間 | 3,100 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 29 |
ソースコード
import sys,math #if len(sys.argv)==2:sys.stdin=open(sys.argv[1]) from collections import defaultdict,deque from itertools import combinations,permutations,accumulate,product from bisect import bisect,bisect_left,bisect_right from heapq import heappop,heappush,heapify #from sortedcontainers import SortedList,SortedSet def input(): return sys.stdin.readline().rstrip() def ii(): return int(input()) def ms(): return map(int, input().split()) def li(): return list(map(int,input().split())) A,B,a,b = ms() for x in range(10**18): if x%A==a and x%B==b: print(x) exit()