結果
| 問題 | No.2811 Calculation Within Sequence |
| コンテスト | |
| ユーザー |
とりゐ
|
| 提出日時 | 2024-07-19 21:21:47 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 159 ms / 2,000 ms |
| + 75µs | |
| コード長 | 231 bytes |
| 記録 | |
| コンパイル時間 | 240 ms |
| コンパイル使用メモリ | 95,980 KB |
| 実行使用メモリ | 120,576 KB |
| 最終ジャッジ日時 | 2026-08-19 01:49:16 |
| 合計ジャッジ時間 | 9,107 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 41 |
ソースコード
n,m=map(int,input().split())
a=list(map(int,input().split()))
b=list(map(int,input().split()))
import math
def calc(c):
g=0
for i in c:
g=math.gcd(i,g)
return g
if calc(b)%calc(a)==0:
print("Yes")
else:
print("No")
とりゐ