Graph Theory

Bellman Ford Algorithm

Posted on

Hello people…! In this post I will talk about another single source shortest path algorithm, the Bellman Ford Algorithm. Unlike Dijkstra’s Algorithm, which works only for a graph positive edge weights, the Bellman Ford Algorithm will give the shortest path from a given vertex for a graph with negative edge weights also. Due to this, […]

Graph Theory

Dijkstra’s Algorithm

Posted on

Hello, people…! In this post, I will talk about one of the fastest single source shortest path algorithms, which is, the Dijkstra’s Algorithm. The Dijkstra’s Algorithm works on a weighted graph with non-negative edge weights and gives a Shortest Path Tree. It is a greedy algorithm, which sort of mimics the working of breadth first search […]

Graph Theory

Snakes and Ladders Game Code

Posted on

Note – Theory of Programming is shifting to YouTube! This post has a video. Watch it at – https://www.youtube.com/watch?v=a3_QGPthIDU Hoping you’ll support the YouTube channel just like you have greatly supported the website! 🙂 Hello people…! In this post, we will discuss about the Snakes and Ladders Game Code, where we find the shortest path […]