結果
| 問題 | No.482 あなたの名は |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2017-02-10 22:30:25 |
| 言語 | PyPy2 (7.3.20) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 213 bytes |
| 記録 | |
| コンパイル時間 | 55 ms |
| コンパイル使用メモリ | 81,124 KB |
| 実行使用メモリ | 100,280 KB |
| 最終ジャッジ日時 | 2026-07-18 11:58:41 |
| 合計ジャッジ時間 | 4,419 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 22 WA * 6 |
ソースコード
n, k = map(int, raw_input().split())
d = map(int, raw_input().split())
x = 0
for i in xrange(n):
if d[i] != i+1:
x += 1
x = (x+1)/2
if x % 2 == k % 2 and x <= k:
print "YES"
else:
print "NO"