Valid BFS? - 1037D - Codeforces
Valid BFS? - 1037D - Codeforces

https://codeforces.com/contest/1037/problem/D

Pretty simple question, but with a bunch of edge cases to handle.
The basic idea is easy to get to, but I still got a few wrong
answers on this.

paramsingh/codechef-solutions,paramsingh/cp,paramsingh/cp,paramsingh/cp,paramsingh/codechef-solutions,paramsingh/codechef-solutions,paramsingh/cp,paramsingh/codechef-solutions,paramsingh/cp