Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dijkstra shortest path algorithm #237

Open
Kanhakhatri065 opened this issue Oct 3, 2020 · 10 comments
Open

Dijkstra shortest path algorithm #237

Kanhakhatri065 opened this issue Oct 3, 2020 · 10 comments
Assignees
Labels
C++ C++ implmentation good first issue Good for newcomers Hacktoberfest Java java implementation Python python implementation

Comments

@Kanhakhatri065
Copy link
Collaborator

Implement Dijkstra shortest path algorithm in any language.

@Kanhakhatri065 Kanhakhatri065 added good first issue Good for newcomers Hacktoberfest Python python implementation C++ C++ implmentation Java java implementation labels Oct 3, 2020
@amarks444
Copy link
Contributor

I would love to do it in C++ if you want?

@kavya1229
Copy link
Contributor

I will do it in python, please assign this to me

@Kanhakhatri065
Copy link
Collaborator Author

@amarks444 do it in C++ and @kavya1229 do it in python.

@amarks444
Copy link
Contributor

amarks444 commented Oct 3, 2020

added Dijkstra in C++.

@Kanhakhatri065
Copy link
Collaborator Author

This looks good but can you also implement it for explicit graphs?

@amarks444
Copy link
Contributor

Yes, I would love to do it, Can you provide some test cases for that..

@Kanhakhatri065
Copy link
Collaborator Author

g.addEdge(0, 1, 4);

g.addEdge(0, 7, 8); 

g.addEdge(1, 2, 8); 

g.addEdge(1, 7, 11); 

g.addEdge(2, 3, 7); 

g.addEdge(2, 8, 2); 

g.addEdge(2, 5, 4); 

g.addEdge(3, 4, 9); 

g.addEdge(3, 5, 14); 

g.addEdge(4, 5, 10); 

g.addEdge(5, 6, 2); 

g.addEdge(6, 7, 1); 

g.addEdge(6, 8, 6); 

g.addEdge(7, 8, 7); 

The first one is source node, the second one is destination node and third value is weight of that edge.

@amarks444
Copy link
Contributor

I have Updated Dijkstras for Implicit Graphs using Set in STL ..#305
You can Merge it..

@amarks444
Copy link
Contributor

I have Updated Dijkstras for Implicit Graphs using Set in STL ..#305
You can Merge it..

You can Merge it..

@Kanhakhatri065
Copy link
Collaborator Author

@amarks444 done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C++ C++ implmentation good first issue Good for newcomers Hacktoberfest Java java implementation Python python implementation
Projects
None yet
Development

No branches or pull requests

3 participants