Improved the variables names
Added the bfs search