An implementation of Djikstra's algorithm in C++