Pergunta de entrevista da empresa McAfee

A question based on Dijkstra's algorithm