結果

問題 No.3066 Collecting Coins Speedrun 1
ユーザー sasa8uyauya
提出日時 2025-03-22 01:38:14
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 64 ms / 2,000 ms
コード長 131 bytes
コンパイル時間 492 ms
コンパイル使用メモリ 82,708 KB
実行使用メモリ 82,512 KB
最終ジャッジ日時 2025-03-22 01:38:18
合計ジャッジ時間 2,964 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 32
権限があれば一括ダウンロードができます

ソースコード

diff #

n=int(input())
c=list(map(int,input().split()))
if c[0]<=0<=c[-1]:
	print((c[-1]-c[0])*2)
else:
	print(max(abs(c[-1]),abs(c[0]))*2)
0