結果
問題 | No.2008 Super Worker |
ユーザー | june19312 |
提出日時 | 2022-07-16 00:17:45 |
言語 | PyPy3 (7.3.15) |
結果 |
TLE
|
実行時間 | - |
コード長 | 299 bytes |
コンパイル時間 | 453 ms |
コンパイル使用メモリ | 86,652 KB |
実行使用メモリ | 138,408 KB |
最終ジャッジ日時 | 2023-09-10 06:40:54 |
合計ジャッジ時間 | 6,845 ms |
ジャッジサーバーID (参考情報) |
judge13 / judge12 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 71 ms
75,668 KB |
testcase_01 | AC | 71 ms
71,388 KB |
testcase_02 | AC | 72 ms
70,936 KB |
testcase_03 | AC | 71 ms
70,836 KB |
testcase_04 | AC | 72 ms
71,116 KB |
testcase_05 | AC | 72 ms
70,836 KB |
testcase_06 | AC | 73 ms
70,948 KB |
testcase_07 | AC | 72 ms
71,060 KB |
testcase_08 | AC | 69 ms
71,176 KB |
testcase_09 | AC | 71 ms
71,240 KB |
testcase_10 | AC | 71 ms
71,360 KB |
testcase_11 | AC | 71 ms
71,308 KB |
testcase_12 | AC | 71 ms
71,180 KB |
testcase_13 | AC | 87 ms
76,492 KB |
testcase_14 | AC | 87 ms
76,544 KB |
testcase_15 | AC | 84 ms
76,464 KB |
testcase_16 | AC | 87 ms
76,484 KB |
testcase_17 | AC | 86 ms
76,632 KB |
testcase_18 | AC | 111 ms
77,360 KB |
testcase_19 | AC | 83 ms
75,616 KB |
testcase_20 | AC | 93 ms
76,420 KB |
testcase_21 | AC | 92 ms
76,540 KB |
testcase_22 | AC | 85 ms
75,336 KB |
testcase_23 | TLE | - |
testcase_24 | -- | - |
testcase_25 | -- | - |
testcase_26 | -- | - |
testcase_27 | -- | - |
testcase_28 | -- | - |
testcase_29 | -- | - |
testcase_30 | -- | - |
testcase_31 | -- | - |
testcase_32 | -- | - |
testcase_33 | -- | - |
testcase_34 | -- | - |
testcase_35 | -- | - |
ソースコード
N = int(input()) A = list(map(int,input().split())) B = list(map(int,input().split())) mod = 10**9+7 C = [] for i in range(N): tmp = (B[i]-1)/A[i] C.append([tmp,i]) C.sort() C.reverse() level = 1 ans = 0 for i,ii in C: ans+=level*A[ii] ans = ans%mod level*=B[ii] print(ans)