結果

問題 No.2921 Seated in Classroom
ユーザー Cecil
提出日時 2024-10-13 15:01:34
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 454 ms / 2,000 ms
コード長 190 bytes
コンパイル時間 307 ms
コンパイル使用メモリ 82,124 KB
実行使用メモリ 76,372 KB
最終ジャッジ日時 2024-10-13 15:01:38
合計ジャッジ時間 3,708 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 5
権限があれば一括ダウンロードができます

ソースコード

diff #

T = int(input())
for _ in range(T):
    N,M = map(int, input().split())
    #print("#")
    if (M+3)//4 <= (N+3)//4:
        print((N+3)//4)
    else:
        d = (M+N+7)//8
        print(d)
0