結果

問題 No.1113 二つの整数 / Two Integers
コンテスト
ユーザー flippergo
提出日時 2026-06-05 19:19:14
言語 PyPy3
(7.3.17)
コンパイル:
pypy3 -mpy_compile _filename_
実行:
pypy3 _filename_
結果
AC  
実行時間 40 ms / 1,000 ms
コード長 347 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 469 ms
コンパイル使用メモリ 84,864 KB
実行使用メモリ 52,096 KB
最終ジャッジ日時 2026-06-05 19:19:16
合計ジャッジ時間 2,191 ms
ジャッジサーバーID
(参考情報)
judge2_1 / judge3_1
純コード判定待ち
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 15
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

def gcd(a,b):
    if b==0:
        return a
    return gcd(b,a%b)
a,b = map(int, input().split())
c = gcd(a,b)
high = c+1
low = 0
ans = c+1
while low+1<high:
    mid = (low+high)//2
    if mid**2>c:
        high = mid
    elif mid**2<c:
        low = mid
    else:
        ans = mid
        break
if ans>c:
    print("Even")
else:
    print("Odd")
0