結果
| 問題 | No.1564 Sum of Products of Pairs |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2023-06-25 21:32:30 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 85 ms / 2,000 ms |
| コード長 | 135 bytes |
| 記録 | |
| コンパイル時間 | 198 ms |
| コンパイル使用メモリ | 85,248 KB |
| 実行使用メモリ | 103,808 KB |
| 最終ジャッジ日時 | 2026-03-23 22:47:24 |
| 合計ジャッジ時間 | 4,033 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge3_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 30 |
ソースコード
n = int(input())
l = sorted(map(int, input().split()), reverse=True)
a = 0
for i in range(n):
a += l[i * 2] * l[i * 2 + 1]
print(a)