結果

問題 No.415 ぴょん
コンテスト
ユーザー JunOnuma
提出日時 2017-06-29 16:44:54
言語 PyPy2
(7.3.15)
結果
AC  
実行時間 83 ms / 1,000 ms
コード長 133 bytes
記録
コンパイル時間 149 ms
コンパイル使用メモリ 77,700 KB
最終ジャッジ日時 2025-12-04 00:19:51
ジャッジサーバーID
(参考情報)
judge4 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 27
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

def gcd(a,b):
    if a % b == 0:
        return b
    return gcd(b, a%b)

n,d = map(int, raw_input().split())
print n / gcd(n,d) - 1
0