Pergunta de entrevista da empresa Nooks

Implement BFS for a toy problem. Why is it slow?