結果
問題 | No.2811 Calculation Within Sequence |
ユーザー |
|
提出日時 | 2024-08-19 09:26:36 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
AC
|
実行時間 | 228 ms / 2,000 ms |
コード長 | 258 bytes |
コンパイル時間 | 610 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 43,264 KB |
最終ジャッジ日時 | 2024-08-19 09:26:47 |
合計ジャッジ時間 | 11,172 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 41 |
ソースコード
import matha, b = map(int, input().split())t = list(map(int, input().split()))s = list(map(int, input().split()))g = 0for i in t:g = math.gcd(g, i)for i in range(b):if s[i] % g != 0:print("No")breakelse:print("Yes")