結果
問題 | No.1416 ショッピングモール |
ユーザー |
👑 ![]() |
提出日時 | 2022-02-17 00:36:06 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 51 ms / 1,000 ms |
コード長 | 150 bytes |
コンパイル時間 | 134 ms |
コンパイル使用メモリ | 82,252 KB |
実行使用メモリ | 69,248 KB |
最終ジャッジ日時 | 2024-06-29 07:23:36 |
合計ジャッジ時間 | 1,733 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 21 |
ソースコード
N=int(input())A=list(map(int,input().split()))A.sort()ans=0for i in range(N):c=-1x=i+1while x!=0:x//=2c+=1ans+=c*A[N-1-i]print(ans)