By Kay Akashi
You are given a positive integer, . You start a game on an -axis after receiving this number. First of all, you are standing on . Starting from , you count the number until . When you are standing at and count , if is not a prime number, you move rightward (hence you move from to ). If is a prime number, you move leftward (hence you move from to ). After completing this game, where will you be?
Note that, is NOT a prime number.
.
.
.
The input consists of one number, .
Output the answer.
5
-5
You are firstly at . Then, you move in a following way: .
200
11646