K-th element#9025

K-th element

1 second
128 megabytes
Very easy

Array of integers and a number are given. Find the -th element in the sorted array (indexing starts from ).

Input

The first line contains two integers and (1 \le n \le 2000, 1 \le k \le n).

The second line contains integers a_i (1 \le i \le n, 1 \le a_i \le 2000).

Output

Print the -th element in the sorted array .

Examples

Example 1

Loading
Loading

Example 2

Loading
Loading