Initial values of elements 2
Execution time limit is 1 second
Runtime memory usage limit is 64 megabytes
Each element of an array with N integers has been modified by adding the array's largest element and subtracting its smallest element. These modified values are provided in the same order as the original array. Your task is to reconstruct the original array values.
Input
The first line contains a natural number N. The second line contains N integers. Each integer does not exceed 100 in absolute value.
Output
Print the original array values in a single line, separated by spaces.
Examples
Input #1
Answer #1
Submissions 4K
Acceptance rate 56%