結果
| 問題 | No.3066 Collecting Coins Speedrun 1 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2025-12-28 14:53:48 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 252 bytes |
| 記録 | |
| コンパイル時間 | 236 ms |
| コンパイル使用メモリ | 95,600 KB |
| 実行使用メモリ | 93,440 KB |
| 最終ジャッジ日時 | 2026-07-19 21:14:54 |
| 合計ジャッジ時間 | 8,177 ms |
|
ジャッジサーバーID (参考情報) |
judge3_1 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | RE * 2 |
| other | RE * 32 |
ソースコード
t=int(input())
for _ in range(t):
n=int(input())
a=sorted(list(map(int,input().split())))
if a[-1]<0:
print(abs(a[0])*2)
elif a[0]>=0:
print(a[-1]*2)
else:
print((abs(min(a[0],a[-1]))+abs(max(a[0],a[-1])))*2)