Harlequin wrote:

Just don't like the Ruby syntax, not very friendly to the eye Smiley

def bfs(e)
    q = []
    e.mark
    yield e
    q.push e
    while not q.empty?
        u = q.shift
        u.edge_iterator do |v|
        if not v.marked?
            v.mark
            yield v
            q.push v
        end   
    end
end
bfs(e) {|v| puts v}



Yer it does look quite horrible now that i've seen that.
Looks like a basic and C mix...

And for 'bfs' anyone else thinkin the same thing im thinkin for what that is meant to stand for.... Tongue Out