Breadth First Search Algorithm Leetcode Sql Top