結果

問題 No.693 square1001 and Permutation 2
ユーザー utsumidaisuke
提出日時 2018-12-19 21:11:50
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 148 bytes
コンパイル時間 85 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 10,752 KB
最終ジャッジ日時 2024-09-25 08:08:17
合計ジャッジ時間 946 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 5 WA * 4
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())

ls = list(map(int,input().split()))
ls.sort()

sq = [i+1 for i in range(n)]

sm = 0
for i,j in zip(sq,ls):
    sm += i-j
print(sm)
0