結果

問題 No.1465 Archaea
ユーザー kept1994
提出日時 2021-09-02 01:57:54
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 401 bytes
コンパイル時間 290 ms
コンパイル使用メモリ 82,792 KB
実行使用メモリ 53,560 KB
最終ジャッジ日時 2024-11-29 00:25:12
合計ジャッジ時間 2,364 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 19 WA * 1
権限があれば一括ダウンロードができます

ソースコード

diff #

#!/usr/bin/env python3
import sys

def main():
    N, K = map(int, input().split())
    cnt = 0
    while N > 1:
        if N % 2 == 1:
            if N <= 3:
                print("NO")
                return
            N -= 3
            cnt += 1
        else:
            N //= 2
            cnt += 1
    print("YES" if cnt <= K else "NO")
    return
        
if __name__ == '__main__':
    main()
0