結果
問題 | No.693 square1001 and Permutation 2 |
ユーザー |
![]() |
提出日時 | 2020-01-19 02:47:36 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
AC
|
実行時間 | 462 ms / 2,000 ms |
コード長 | 269 bytes |
コンパイル時間 | 103 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 44,616 KB |
最終ジャッジ日時 | 2024-06-28 18:00:01 |
合計ジャッジ時間 | 6,322 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 9 |
ソースコード
import sysread = sys.stdin.buffer.readreadline = sys.stdin.buffer.readlinereadlines = sys.stdin.buffer.readlinesimport numpy as npN = int(readline())A = np.array(read().split(),np.int64)A.sort()x = np.arange(1,N+1) - Aanswer = np.abs(x).sum()print(answer)