結果

問題 No.683 Two Operations No.3
ユーザー raven7959raven7959
提出日時 2021-10-10 10:39:09
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 405 bytes
コンパイル時間 609 ms
コンパイル使用メモリ 87,004 KB
実行使用メモリ 71,548 KB
最終ジャッジ日時 2023-10-12 05:27:47
合計ジャッジ時間 2,636 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 71 ms
71,516 KB
testcase_01 AC 78 ms
71,436 KB
testcase_02 AC 79 ms
71,380 KB
testcase_03 AC 78 ms
71,476 KB
testcase_04 AC 77 ms
71,384 KB
testcase_05 WA -
testcase_06 AC 78 ms
71,152 KB
testcase_07 AC 78 ms
71,200 KB
testcase_08 AC 84 ms
71,532 KB
testcase_09 AC 83 ms
71,004 KB
testcase_10 AC 82 ms
71,052 KB
testcase_11 WA -
testcase_12 WA -
testcase_13 AC 78 ms
71,244 KB
testcase_14 AC 79 ms
71,392 KB
testcase_15 AC 80 ms
71,488 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

a,b=map(int,input().split())
def check(a,b):
    if a*b==0:
        return True
    if a%2==1 and b%2==1:
        return False
    elif a%2+b%2==1:
        return True
    else:
        if a%4!=0 and b%4!=0:
            return False
        else:
            if a%4==0:
                check(a//2,b-1)
            else:
                check(a-1,b//2)
if check(a,b):
    print("Yes")
else:
    print("No")
0