#T76. 和为给定数

和为给定数

Description

Given several integers, determine if there exists a pair of numbers whose sum equals a given value.

Input Format

The first line contains an integer n (0 < n ≤ 100,000), representing the count of integers.
The second line contains n integers. The range of these integers is between 0 and 10^8.
The third line contains an integer m (0 ≤ m ≤ 2^30), representing the target sum.

Output Format

If a pair of numbers with the sum m exists, output the two integers separated by a single space, with the smaller number first and the larger number second.
If multiple pairs satisfy the condition, prioritize the pair with the smallest smaller number.
If no such pair is found, output No.

4
2 5 1 4
6

1 5

Hint

Watch out for pitfalls!