Skip to content

Instantly share code, notes, and snippets.

View MrPowers's full-sized avatar
🤓
Writing OSS code

Matthew Powers MrPowers

🤓
Writing OSS code
View GitHub Profile
@manoamaro
manoamaro / gist:3000167
Created June 26, 2012 23:36
Bellman-Ford algorithm
class Vertice
attr_accessor :predecessor, :d, :name
def initialize(n)
@name = n
end
end
class Edge
attr_accessor :source, :destination, :w
def initialize(s,d,w)