
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
Let the sequence $a_n$ be an arithmetic sequence, and its sum of the first $n$ terms be $S_n$. Given that $a_1+a_3+a_8=99$ and $a_5=31$, find the value of $k$ such that for all $n \in \mathbb{N}^*$, $S_n \leq S_k$ always holds.

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