C. Magic
time limit per test
6 seconds
memory limit per test
1024 megabytes
input
standard input
output
standard output
Example
Input
3
Output
0 15 5
7 1 12
13 4 3