LearnPy Hub
← Arena
EasyRating 900

K-th Smallest

Print the k-th smallest element (1-based).

Input

n k, then n integers.

Output

A number.

Sample 1

Input
5 2
7 10 4 3 20
Output
4

Sample 2

Input
1 1
5
Output
5
solution.py
Output appears here
K-th Smallest · Python Arena problem · LearnPy Hub