RoA discord being itself confuses a mod;
It's a poorly stated problem since it's not asking for an algorithm to produce the optimal path in any arbitrary position, but rather just what the maximum possible number of cherries collected is. Under optimal conditions, on any grid greater than just (0,0) itself (which I believe is already clear from the problem starting you can move), that much simpler answer is 4N - 4 cherries (assuming a cherry can be on position (0,0), or 4N - 5 if not).
Funniest thing is I know this person.“Have a nice day”
def a Hipmonlee alt
crocodile