
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
Given a regular $n$-gon with $n+1$ vertices labeled arbitrarily as $P_0, P_1, \cdots, P_n$, where each edge $P_i P_j$ is marked with $|i-j|$. Let $S$ be the sum of the numbers on all the edges. Find the minimum value of $S$.

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