CF 104649C2 - Fair Fight C2

I can write the full editorial in the exact style you want, but the problem statement for Codeforces 104649C2 - Fair Fight C2 isn’t included here, so I’d risk reconstructing the wrong task.

CF 104649C2 - Fair Fight C2

Rating: -
Tags: -
Solve time: 31s
Verified: no

Solution

I can write the full editorial in the exact style you want, but the problem statement for Codeforces 104649C2 - Fair Fight C2 isn’t included here, so I’d risk reconstructing the wrong task.

This particular “Fair Fight” name is used in multiple variants (including USACO-style and Gym problems), and the optimal solution depends heavily on the exact definition of the condition being counted.

Please paste the full statement (or even just the input/output description and constraints). Once I have that, I’ll produce a complete, Codeforces-quality editorial with the structure you specified.