Permutation p is an ordered set of integers p_1,  p_2,  ...,  p_{n}, consisting of n distinct positive integers, each of them doesn't exceed n. We'll denote the i-th element of permutation p as p_{i}. We'll call number n the size or the length of permutation p_1,  p_2,  ...,  p_{n}.

The decreasing coefficient of permutation p_1, p_2, ..., p_{n} is the number of such i (1 ≤ i < n), that p_{i} > p_{i} + 1.

You have numbers n and k. Your task is to print the permutation of length n with decreasing coefficient k.


-----Input-----

The single line contains two space-separated integers: n, k (1 ≤ n ≤ 10^5, 0 ≤ k < n) — the permutation length and the decreasing coefficient.


-----Output-----

In a single line print n space-separated integers: p_1, p_2, ..., p_{n} — the permutation of length n with decreasing coefficient k. 

If there are several permutations that meet this condition, print any of them. It is guaranteed that the permutation with the sought parameters exists.


-----Examples-----
Input
5 2

Output
1 5 2 4 3

Input
3 0

Output
1 2 3

Input
3 2

Output
3 2 1

Difficulty: interview

Starter code:

Solutions:
rd = lambda: list(map(int, input().split()))

n, k = rd()
print(' '.join(map(str, list(range(n, n-k,-1))+list(range(1,n-k+1)))))

import sys
my_file = sys.stdin
#my_file = open("input.txt", "r")
nums = [int(i) for i in my_file.readline().split(" ")]
n = nums[0]
k = nums[1]
p = list(range(1, n+1))
p = p[n-1:n-k-1:-1]+p[:n-k]
for i in p:
    print(i, end=' ')

n,k=map(int,input().split())

L=list(range(1,n+1))
if(k!=0):
    i=-k+n
    s=L[-k:-1]+[L[-1]]
    s.reverse()
    L=s+L[:i]

for i in range(n-1):
    print(L[i],end=" ")

print(L[-1])


import sys

(n, k) = list(map(int, input().split()))

a = list(range(1, k+2))[::-1] + list(range(k+2, n+1))

print(*a)


n, k = map(int, input().split())
for i in list(range(n, n - k, -1)) + list(range(1, n - k + 1)):
    print(i, end = ' ')


def number_of_inversions(l):
    counter = 0
    for i in range(0, len(l)-1):
        if l[i] > l[i+1]:
            counter += 1
    return counter

def is_right_choice(l, k):
    return number_of_inversions(l) == k


def make_k_inversions(n, k):
    length_of_inverted = k + 1
    length_of_non_inverted = n - length_of_inverted

    non_inverted = list(range(1, length_of_non_inverted + 1))
    inverted = list(range(length_of_non_inverted + 1, n+1))
    inverted.reverse()
    
    return non_inverted + inverted

          


def main():
    first_line = input()
    first_line = first_line.split()
    
    n = int(first_line[0])
    k = int(first_line[1])

    l = make_k_inversions( n, k)

    output = ""
    for item in l:
        output += str(item) + " "
    print(output)



    
    
    
main()


n, k = map(int, input().split())
for i in range(k+1, 0, -1):
    print(i, end = ' ')
for i in range(k+2, n+1):
    print(i, end = ' ')



b=list(map(int,input().split()))
a=[]
for i in range(1,b[0]+1):
    a.append(i)
c=a[:b[1]+1]
c.reverse()
a=c+a[b[1]+1:]
for j in a:
    print(j,end=' ')


a,b=list(map(int,input().split()))
for i in range(b+1,0,-1):
    print(i,end=' ')
for i in range(b+2,a+1):
    print(i,end=' ')

a,b=list(map(int,input().split()))
for i in list(range(b+1,0,-1))+list(range(b+2,a+1)):
    print(i,end=' ')

n,k = input().split()
n,k = int(n),int(k)

for i in range(k+1):
    print(k+1-i,end=" ")
for i in range(k+2,n+1):
    print(i,end=" ")


n,k=map(int,input().split())

L=list(range(1,n+1))

for i in range(-1,-k-1,-1):
    print(L[i],end=" ")
for i in range(n-k):
    print(L[i],end=" ")


def main() -> int:
    (n, k) = map(int, input().split())
    head = [i for i in range(k + 1, 0, -1)]
    tail = [i for i in range(k + 2, n + 1, 1)]

    print(' '.join(str(i) for i in head + tail))

    return 0


def __starting_point():
    main()
__starting_point()

a, b = map(int, input().split())
seq = [x+1 for x in range(a)]

if a > b+1:
    seq = seq[:a-b-1]+seq[:a-b-2:-1]
else:
    seq = seq[::-1]

print(*seq, sep=' ')


n, k = map(int, input().split())
print(*list(reversed(range(1, k + 2))) + list(range(k + 2, n + 1)))

sa=input().split(' ')
nums=int(sa[0])
decs=int(sa[1])
string=''
for x in range(nums, nums-decs, -1):
    string+=str(x)
    string+=' '
for x in range(1, nums-decs+1):
    string+=str(x)
    string+=' '
print(string.strip())


n,k=list(map(int,input().split()))
i=1
while i<(n-k):
	print(i,end='')
	print(' ',end='')
	i+=1
i=n
while i>n-k-1:
	print(i,end='')
	print(' ',end='')
	i-=1

n, k = (int(x) for x in input().split())
for i in range(n, n - k, -1):
    print(i, end=' ')
for i in range(1, n - k + 1):
    print(i, end=' ')

import sys

n, k = [int(x) for x in (sys.stdin.readline()).split()]

j = 0
result = []
for i in range(n, 0, -1):
    if(j < k):
        result.append(str(i))
        j += 1
    else:
        break

for i in range(1, n - k + 1):
    result.append(str(i))
    
print(" ".join(result))

n,k=map(int,input().split())

l=[0]*n
for i in range(n,n-k,-1):
    l[n-i]=i
for i in range(1,n-k+1):
    l[i+k-1]=i
for i in range(n):
    print(l[i],end=" ")

n, k = [int(x) for x in input().split()]
for i in range(n - k - 1):
	print(i + 1, end = ' ')
for i in range(k + 1):
	print(n - i, end = ' ')
print()


def main():
    n, k =  map(int, input().strip().split())
    return list(range(n, n - k, -1)) + list(range(1, n - k + 1))


print(*main())

'''
Created on ١٣‏/١٢‏/٢٠١٤

@author: mohamed265
'''
t = input().split()
for i in range(int(t[1])): print(int(t[0]) - i, end=' ')
for i in range(int(t[0]) - int(t[1])): print(i + 1, end=' ')