
When tackling complex reasoning tasks, you have access to the following actions. Use them as needed to progress through your thought process.

[ASSESS]

[ADVANCE]

[VERIFY]

[SIMPLIFY]

[SYNTHESIZE]

[PIVOT]

[OUTPUT]

You should strictly follow the format below:

[ACTION NAME]

# Your action step 1

# Your action step 2

# Your action step 3

...

Next action: [NEXT ACTION NAME]


system
There are  $n\geq 3$  pupils standing in a circle, and always facing the teacher that stands at the centre of the circle. Each time the teacher whistles, two arbitrary pupils that stand next to each other switch their seats, while the others stands still. Find the least number  $M$  such that after  $M$  times of whistling, by appropriate switchings, the pupils stand in such a way that any two pupils, initially standing beside each other, will finally also stand beside each other; call these two pupils  $ A$  and  $ B$ , and if  $ A$  initially stands on the left side of  $ B$  then  $ A$  will finally stand on the right side of  $ B$ .

Present the answer in LaTex format: \boxed{Your answer}
user