Yelp Interview Question

Pretty straightforward BFS graph question