#ENGLISHP26. The Nearest Number
The Nearest Number
Description
Given a sequence of N number and K. Find the nearest number X in the sequence that the absolute value of (X minus K) is minimum.
Input Format
First line: two positive integers N (N <= 100) and K (K <= 100000).
Second line: N positive integers (<= 100000).
Output Format
One integer X.
4 5
2 4 7 8
4