#P12336. Constructing a Quadruple
Constructing a Quadruple
Constructing a Quadruple
Given a positive integer a, construct a quadruple of positive integers \((a, b, c, d)\) satisfying the following conditions:
- \( \sqrt{a^2+b^2+c^2+d^2} = a\oplus b\oplus c\oplus d \), where \(\oplus\) denotes the bitwise XOR operation.
- \( a < b < c < d < 2^{63} \).
If no such quadruple exists, output -1
.
Note: The input gives the value of a. You need to choose b, c, and d accordingly. If a valid quadruple cannot be constructed, simply output -1
.
inputFormat
The input consists of a single line containing a positive integer a (\(1 \le a < 2^{63}\)).
outputFormat
If a valid quadruple \((a, b, c, d)\) exists, print the four space-separated positive integers. Otherwise, print -1
.
sample
1
-1