#D11659. Cyclic Shift Sort

    ID: 9696 Type: Default 2000ms 268MiB

Cyclic Shift Sort

Cyclic Shift Sort

Problem

Given a permutation of length N N P=P1,P2, ldots,PN P = \\ {P_1, P_2, \ ldots, P_N \\} and the integer K K . Determine if the permutation P P can be monotonically increased by repeating the following operation any number of times 0 0 or more.

  • Choose the integer x (0 lex leNK) x \ (0 \ le x \ le N-K) . Patrol right shift around Px+1, ldots,Px+K P_ {x + 1}, \ ldots, P_ {x + K}

However, the cyclic right shift of the subsequence U=U1, ldots,UM U = U_1, \ ldots, U_M means that U=U1, ldots,UM U = U_1, \ ldots, U_M is changed to U=UM,U1, ldots,UM1 U = U_M, U_1, \ ldots, U_ {M-1} . Means to change.

Constraints

The input satisfies the following conditions.

  • 2 leqK leqN leq105 2 \ leq K \ leq N \ leq 10 ^ 5
  • 1 leqPi leqN (1 leqi leqN) 1 \ leq P_i \ leq N \ (1 \ leq i \ leq N)
  • Pi neqPj (i neqj) P_i \ neq P_j \ (i \ neq j)
  • All inputs are integers

Input

The input is given in the following format.

N N K K P1 P_1  ldots \ ldots PN P_N

Permutation length N N and integer K K are given in the first row, separated by blanks. The elements of the permutation P P are given in the second row, separated by blanks.

Output

Print "Yes" if you can monotonically increase P P , otherwise print "No" on the 1 1 line.

Examples

Input

3 3 2 3 1

Output

Yes

Input

3 2 1 2 3

Output

Yes

Input

3 3 3 2 1

Output

No

inputFormat

input satisfies the following conditions.

  • 2 leqK leqN leq105 2 \ leq K \ leq N \ leq 10 ^ 5
  • 1 leqPi leqN (1 leqi leqN) 1 \ leq P_i \ leq N \ (1 \ leq i \ leq N)
  • Pi neqPj (i neqj) P_i \ neq P_j \ (i \ neq j)
  • All inputs are integers

Input

The input is given in the following format.

N N K K P1 P_1  ldots \ ldots PN P_N

Permutation length N N and integer K K are given in the first row, separated by blanks. The elements of the permutation P P are given in the second row, separated by blanks.

outputFormat

Output

Print "Yes" if you can monotonically increase P P , otherwise print "No" on the 1 1 line.

Examples

Input

3 3 2 3 1

Output

Yes

Input

3 2 1 2 3

Output

Yes

Input

3 3 3 2 1

Output

No

样例

3 2
1 2 3
Yes