結果
問題 |
No.989 N×Mマス計算(K以上)
|
ユーザー |
![]() |
提出日時 | 2020-02-14 21:31:01 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
WA
|
実行時間 | - |
コード長 | 493 bytes |
コンパイル時間 | 120 ms |
コンパイル使用メモリ | 12,672 KB |
実行使用メモリ | 24,516 KB |
最終ジャッジ日時 | 2024-10-06 10:43:04 |
合計ジャッジ時間 | 2,052 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 12 WA * 6 |
ソースコード
# coding: utf-8 # Your code here! import sys readline = sys.stdin.readline read = sys.stdin.read n,m,k = [int(i) for i in readline().split()] x = read().split() op = x[0] b = list(map(int,x[1:m+1])) a = list(map(int,x[m+1:])) #a.sort() b.sort() from bisect import bisect_left as bis #print(op,b,a) if op == "+": ans = 0 for ai in a: ans += m - bis(b,k-ai) print(ans) else: ans = 0 for ai in a: ans += m - bis(b,k//ai) print(ans)