Skip to content

balajimk/dijkstraReact

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dijkstraReact

Coding Dijkstra's shortest path algorithm in React.

You can learn the Dijkstra's algorithm from https://www.youtube.com/watch?v=pVfj6mxhdMw.

How to execute the code online

Browse https://repl.it/@BalajiMKala/dijkstraReact and click Run button.

How to run the code locally

Clone or download the code from this repository. Open the folder in Visual Studio code or your preferred text editor. Install packages by running the command in the prompt / terminal"

npm install

and start the development serverwith

npm start

Logic in Python

The actual logic is coded in python at https://github.com/balajimk/dijkstraPython

Using the application

  1. Double click on the page to add new vertex.
  2. Click on any vertex to select / deselect the vertex.
  3. When one vertex is selected, click on another vertex to connect with a edge. This will have a defauly weight/distance of 1.
  4. Click any edge to select and the change the value by changing the text in the box on top.
  5. Click any vertex and click on Select Start or Select Target to select the From and To vertices for calculating shortest path.
  6. Click Calulate to find the shortest path.
  7. Click Reset path button to re-calculate new values.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published