結果

問題 No.989 N×Mマス計算(K以上)
ユーザー 👑 H20H20
提出日時 2021-07-15 11:13:18
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 352 bytes
コンパイル時間 289 ms
コンパイル使用メモリ 87,224 KB
実行使用メモリ 91,196 KB
最終ジャッジ日時 2023-09-17 16:35:48
合計ジャッジ時間 3,766 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 77 ms
71,324 KB
testcase_01 AC 77 ms
71,384 KB
testcase_02 AC 78 ms
71,036 KB
testcase_03 AC 79 ms
71,392 KB
testcase_04 AC 77 ms
71,420 KB
testcase_05 AC 77 ms
71,472 KB
testcase_06 WA -
testcase_07 AC 77 ms
71,220 KB
testcase_08 WA -
testcase_09 AC 79 ms
71,088 KB
testcase_10 AC 174 ms
84,268 KB
testcase_11 WA -
testcase_12 WA -
testcase_13 AC 131 ms
85,628 KB
testcase_14 WA -
testcase_15 WA -
testcase_16 AC 156 ms
82,132 KB
testcase_17 AC 132 ms
85,724 KB
testcase_18 AC 159 ms
80,344 KB
testcase_19 AC 162 ms
89,100 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import bisect
N,M,K = map(int,input().split())
B = list(input().split())
OP = B[0]
B = list(map(int, B[1:]))
A = []
for _ in range(N):
    A.append(int(input()))
A.sort()
B.sort()
ANS = 0
if OP=='+':
    for a in A:
        ANS += M-bisect.bisect_left(B,K-a)
else:
    SB = sum(B)
    for a in A:
        ANS += M-bisect.bisect_left(B,K//a)
print(ANS)
0