Pregunta de entrevista de IXL Learning

rectangle overlap and a bfs question