Skip to content

This repository implements and compares two versions of the Floyd-Warshall algorithm, used for finding shortest paths in a weighted graph with positive or negative edge weights.

Notifications You must be signed in to change notification settings

Exp1ry/floyd-warshall-iterative-vs-recursive

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

README

Please complete this document

What is this repository for?

This repository implements and compares two versions of the Floyd-Warshall algorithm, used for finding shortest paths in a weighted graph with positive or negative edge weights. The two versions include:

Recursive Version: Implements the Floyd-Warshall algorithm recursively. Iterative Version: Implements the classic iterative approach of Floyd-Warshall.

How do I get set up?

git clone https://github.com/Exp1ry/floyd-warshall-iterative-vs-recursive.git cd src

Running the scripts

Run the recursive script: python3 recursion/recursive_floyd.py

Run the iterative script: python3 iterative/iterative_floyd.py

Run tests: python3 -m unittest tests/unittests.py

Requirements

Python 3.6+

No external dependencies

About

This repository implements and compares two versions of the Floyd-Warshall algorithm, used for finding shortest paths in a weighted graph with positive or negative edge weights.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages