The R1 company wants to hold a web search championship. There were n computers given for the competition, each of them is connected to the Internet. The organizers believe that the data transfer speed directly affects the result. The higher the speed of the Internet is, the faster the participant will find the necessary information. Therefore, before the competition started, each computer had its maximum possible data transfer speed measured. On the i-th computer it was a_{i} kilobits per second.

There will be k participants competing in the championship, each should get a separate computer. The organizing company does not want any of the participants to have an advantage over the others, so they want to provide the same data transfer speed to each participant's computer. Also, the organizers want to create the most comfortable conditions for the participants, so the data transfer speed on the participants' computers should be as large as possible.

The network settings of the R1 company has a special option that lets you to cut the initial maximum data transfer speed of any computer to any lower speed. How should the R1 company configure the network using the described option so that at least k of n computers had the same data transfer speed and the data transfer speed on these computers was as large as possible?


-----Input-----

The first line contains two space-separated integers n and k (1 ≤ k ≤ n ≤ 100) — the number of computers and the number of participants, respectively. In the second line you have a space-separated sequence consisting of n integers: a_1, a_2, ..., a_{n} (16 ≤ a_{i} ≤ 32768); number a_{i} denotes the maximum data transfer speed on the i-th computer.


-----Output-----

Print a single integer — the maximum Internet speed value. It is guaranteed that the answer to the problem is always an integer.


-----Examples-----
Input
3 2
40 20 30

Output
30

Input
6 4
100 20 40 20 50 50

Output
40



-----Note-----

In the first test case the organizers can cut the first computer's speed to 30 kilobits. Then two computers (the first and the third one) will have the same speed of 30 kilobits. They should be used as the participants' computers. This answer is optimal.

Difficulty: interview

Starter code:

Solutions:
n, k = map(int, input().split())
s = sorted(list(map(int, input().split())), reverse = True)
print(s[k - 1])

def main():
	n, k = map(int, input().split())
	A = list(map(int, input().split()))
	A.sort(reverse = True)
	print(A[k - 1])
main()

import heapq
n, uch = list(map(int, input().split()))
speeds = list(map(int, input().split()))
# n - kompi
# na i kompe skorost' a[i]
# uch uchastnikov
# orgi hot'yat ravn skorost' no max

godnie = heapq.nlargest(uch, speeds)
print(min(godnie))


n, k = list(map(int, input().split()))
a = sorted(list(map(int, input().split())))
print(a[-k])

n, k = list(map(int, input().split()))
a = list(map(int, input().split()))
a = sorted(a,reverse=True)
a = a[:k]
print(a[-1])


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

L=list(map(int,input().split()))

L.sort(reverse=True)

print(L[k-1])


n, k = map(int, input().split())
a = list(reversed(sorted(list(map(int, input().split())))))
print(a[k - 1])

N,K= list(map(int, input().split()))
Speeds = list(map(int,input().split()))
Speeds.sort()
print(Speeds[-K])


n, k = list(map(int, input().split()))
numbers = sorted(list(map(int, input().split())), reverse = True)
print(numbers[k - 1])


[n, k], speed = list(map(int, input().split())), sorted(map(int, input().split()), reverse = True)
print(speed[k - 1])


n, k = map(int, input().split())
s = list(map(int, input().split()))
s = list(sorted(s))
print(min(s[n - k:]))

n, k = map(int, input().split())
a = list(map(int, input().split()))
a.sort(reverse = True)
print(a[k - 1])

n, k = map(int, input().split())
S = list(map(int, input().split()))
S.sort(reverse = True)
print(S[k - 1])

n,k=list(map(int,input('').split()))                   
a=list(map(int,input('').split()))
a=list(reversed(sorted(a)))
print(a[k-1])

                



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

A.sort()

print(A[n - k])

b=input().split()
n=int(b[0])
k=int(b[1])
a=input().split()
ai=[]
for i in range(n):
    ai.append(int(a[i]))
ai.sort()
print(ai[n-k])


n, k = list(map(int, input().split()))
data = list(map(int, input().split()))
line = [0] * n
maxx = 0
for i in range(n):
    count = 0
    for j in range(n):
        if data[i] <= data[j]:
            count += 1
    line[i] = count
    if count >= k:
        maxx = max(maxx, data[i])
print(maxx)


n, k = map(int, input().split())
A = sorted(list(map(int, input().split())))
print(A[n - k])

n,k=list(map(int,input().split()))
lis=list(map(int,input().split()))
lis.sort()
lis.reverse()
print(lis[k-1])


n, k = map(int, input().split());
array = list(map(int, input(). split()));
array.sort(reverse = True);
print(array[k - 1]);

import sys
line = str.split(input()," ")
n = int(line[0])# num comp
k = int(line[1])# num par

line = str.split(str(input())," ")
speeds = []
for s in line:
    speeds.append(int(s))

sspeeds = speeds
sspeeds.sort()
sspeeds.reverse()

sys.stdout.write(str(sspeeds[k-1]))


n,k=list(map(int,input().split()))
a=list(map(int,input().split()))
a.sort()
mini=0
b=[]
for i in range(n-1,n-k-1,-1):
    b.append(a[i])
b.sort()
print(b[0])


n,k=map(int,input().split())
a=list(map(int,input().split()))
a.sort(reverse=True)
print(a[k-1])

n, k = list(map(int, input().split()))
print(list(reversed(list(sorted(list(map(int, input().split()))))))[k - 1])