Problem

7 /23


Based on the Unified State Examination 2016 - 2

Problem

Given N pairs of numbers. From each pair, you need to choose one so that the sum of the selected numbers is the smallest possible and is not divisible by 4. In the first line, enter the number N, not exceeding 100,000.
If there are no such numbers, output "no".
The input is first the number of pairs, then the pairs themselves. Modulo numbers do not exceed 30,000.
 

 

Examples
# Input Output
1 6
10 10
17
25
4 5
6 9
13 13
37