A radio scanner knows n station frequencies (integers, possibly repeated). Given a target dial value x and an integer k, choose the k frequencies that are closest to x, where closeness is measured by absolute difference |f - x|. When two frequencies are equally close, prefer the one with the smaller value. After choosing the k frequencies, output them sorted in ascending order.
Input format
Line 1: three integers n, k, and x.
Line 2: n space-separated integers, the frequencies.
Output format
k space-separated integers on one line: the chosen frequencies sorted ascending.
Constraints
- 1 <= k <= n <= 100000
- -1000000000 <= x <= 1000000000
- -1000000000 <= each frequency <= 1000000000