Woburn Challenge 1999 - Suicidal
The Impossible Mission Force had some cutbacks and Ethan Hunt was
disavowed. His story is now told in the sequel to the popular Good Will
Hunting, tentatively titled Good Ethan Hunt. Ethan needs to pay the
bills in his currently unemployed state and has taken a job as a janitor
at a local college. Here, his tasks include resetting the key
combinations to several doors periodically. However, the man's a genius
and choosing a random code would be beneath him and so he will reset the
code in the following way: The code will involve all the numbers from
For example, if
Input Specification
Next
Output Specification
For each value of
Sample Input
1
4
Sample Output
3 4 1 0 2
Comments
Not sure if this counts as a spoiler, but the problem is quite similar to https://dmoj.ca/problem/ioi09pp3 despite being worded quite differently