結果
| 問題 | No.1224 I hate Sqrt Inequality |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2020-09-29 15:07:58 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 297 bytes |
| 記録 | |
| コンパイル時間 | 551 ms |
| コンパイル使用メモリ | 82,448 KB |
| 実行使用メモリ | 66,964 KB |
| 最終ジャッジ日時 | 2024-07-03 22:38:22 |
| 合計ジャッジ時間 | 1,666 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 RE * 1 |
| other | AC * 4 RE * 9 |
ソースコード
#!/usr/bin/env python3
import sys
import math
readline = sys.stdin.buffer.readline
sys.setrecursionlimit(10 ** 7)
a, b = map(int, readline().split())
g = math.gcd(a, b)
a //= g
b //= g
while True:
x = math.gcd(b, 10)
if x == 1:
break
b /= x
print('Yes' if b != 1 else 'No')