結果

問題 No.1987 Sandglass Inconvenience
ユーザー lam6er
提出日時 2025-03-20 20:22:18
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 34 ms / 2,000 ms
コード長 253 bytes
コンパイル時間 364 ms
コンパイル使用メモリ 82,532 KB
実行使用メモリ 54,096 KB
最終ジャッジ日時 2025-03-20 20:24:30
合計ジャッジ時間 1,799 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 22
権限があれば一括ダウンロードができます

ソースコード

diff #

import math

a, b, c = map(int, input().split())
X = int(input())

# Calculate the GCD of a, b, and c
gcd_ab = math.gcd(a, b)
gcd_abc = math.gcd(gcd_ab, c)

# Check if X is divisible by gcd_abc
if X % gcd_abc == 0:
    print("Yes")
else:
    print("No")
0