
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 \( n \) be a non-negative integer defined by \( f(0) = 0 \), \( f(1) = 1 \), \( f(n) = f\left(\left\lfloor \frac{n}{2} \right\rfloor\right) + n - 2\left\lfloor \frac{n}{2} \right\rfloor \). Determine the maximum value of \( f(n) \) for \( 0 \leqslant n \leqslant 1991 \). (Here, \(\left\lfloor x \right\rfloor\) represents the greatest integer less than or equal to \( x \)).

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