Hi,

I have been trying to implement the solution to https://oj.uz/problem/view/BOI16_park which is in the DSU category for usaco.guide. I’ve been doing the solution described in the usaco.guide editorial written here https://usaco.guide/solutions/baltic-16-park

My implementation gets one case on subtask 1 and one case on subtask 3 but ultimately gets 0/100. Here is my code: https://hastebin.com/zusopoyuze.cpp

In my code I assigned the borders n(top), n+1(right), n+2(bottom), and n+3(left). If anybody could tell me what I’m doing wrong or maybe just give me a better way to implement it that would be nice.

Thanks!