結果

問題 No.2008 Super Worker
ユーザー june19312june19312
提出日時 2022-07-15 23:50:25
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 317 bytes
コンパイル時間 345 ms
コンパイル使用メモリ 87,220 KB
実行使用メモリ 143,376 KB
最終ジャッジ日時 2023-09-10 06:01:57
合計ジャッジ時間 7,290 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 74 ms
75,744 KB
testcase_01 WA -
testcase_02 AC 73 ms
71,100 KB
testcase_03 AC 74 ms
71,088 KB
testcase_04 AC 74 ms
71,220 KB
testcase_05 AC 73 ms
71,148 KB
testcase_06 AC 74 ms
71,256 KB
testcase_07 AC 73 ms
71,372 KB
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 RE -
testcase_19 RE -
testcase_20 RE -
testcase_21 RE -
testcase_22 RE -
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 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
A = list(map(int,input().split()))
B = list(map(int,input().split()))
mod = 10**9+7

C = []

for i,v in enumerate(A):
    tmp = (B[i]-1)/A[i]
    C.append([tmp,i])

C.sort()
C.reverse()

level = 1
ans = 0

for i,v in enumerate(C):
    tmp1 = v[1]
    ans+=level*A[tmp1]
    level*=B[tmp1]

print(ans)
0