Can anybody please hack/prove my solution to Round 1038 Problem D?

Revision en2, by k1r1t0, 2025-07-20 00:48:11

The idea behind my solution is that in the optimal path you don't enter any vertex after the first time it can be entered + n. I wonder if there is a proof that this works correctly or a way to disprove it, but I'm having trouble finding either. If anyone is interested, please help.

329877256

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English k1r1t0 2025-07-20 00:48:11 2 Tiny change: 'rectly or way to di' -> 'rectly or a way to di'
en1 English k1r1t0 2025-07-20 00:46:47 373 Initial revision (published)