結果

問題 No.1280 Beyond C
ユーザー 👑 SPD_9X2SPD_9X2
提出日時 2020-11-06 21:30:58
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 157 ms / 2,000 ms
コード長 387 bytes
コンパイル時間 632 ms
コンパイル使用メモリ 87,048 KB
実行使用メモリ 92,656 KB
最終ジャッジ日時 2023-09-29 18:15:03
合計ジャッジ時間 4,264 ms
ジャッジサーバーID
(参考情報)
judge14 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 74 ms
71,396 KB
testcase_01 AC 74 ms
71,328 KB
testcase_02 AC 73 ms
71,516 KB
testcase_03 AC 74 ms
71,364 KB
testcase_04 AC 73 ms
71,328 KB
testcase_05 AC 72 ms
71,256 KB
testcase_06 AC 74 ms
71,244 KB
testcase_07 AC 72 ms
71,316 KB
testcase_08 AC 73 ms
71,464 KB
testcase_09 AC 74 ms
71,544 KB
testcase_10 AC 74 ms
71,520 KB
testcase_11 AC 79 ms
76,660 KB
testcase_12 AC 74 ms
71,452 KB
testcase_13 AC 80 ms
76,672 KB
testcase_14 AC 80 ms
76,624 KB
testcase_15 AC 120 ms
89,540 KB
testcase_16 AC 110 ms
87,456 KB
testcase_17 AC 122 ms
90,040 KB
testcase_18 AC 125 ms
92,652 KB
testcase_19 AC 139 ms
92,656 KB
testcase_20 AC 155 ms
92,608 KB
testcase_21 AC 155 ms
92,572 KB
testcase_22 AC 157 ms
92,384 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from sys import stdin

N,M,C = map(int,stdin.readline().split())
a = list(map(int,stdin.readline().split()))
b = list(map(int,stdin.readline().split()))

b.sort()
ans = 0

for i in range(N):

    na = a[i]
    l = -1
    r = M

    while r-l != 1:

        m = (l+r)//2

        if b[m] * na > C:
            r = m
        else:
            l = m

    ans += r

print (1 - ans / (N*M))
0