結果

問題 No.482 あなたの名は
ユーザー jamad
提出日時 2017-08-30 01:04:21
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 183 bytes
コンパイル時間 131 ms
コンパイル使用メモリ 12,672 KB
実行使用メモリ 29,540 KB
最終ジャッジ日時 2024-11-06 09:52:02
合計ジャッジ時間 3,990 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 20 WA * 8
権限があれば一括ダウンロードができます

ソースコード

diff #

N,K=map(int,input().split())

D=[ x-1 for x in map(int,input().split())]

Z=[int(D[i]==i) for i in range(N)].count(0)

swaptime=(Z+1)//2

print(('YES','NO')[(K-swaptime)%2==1])

    
0