Jump to content

Talk:Floyd–Warshall algorithm

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Ropez (talk | contribs) at 22:41, 10 May 2005. The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
(diff) ← Previous revision | Latest revision (diff) | Newer revision → (diff)

Change pseudocode to Wikicode?

The pseudocode in this article is very hard to understand. I suggest changing it to something like this:

Template:Wikicode

function fw(int[0..n,0..n] graph) {
    var int[0..n,0..n] dist := graph
    for k from 0 to n
        for i from 0 to n
            for j from 0 to n
                if dist[i,j] > dist[i,k] + dist[k,j]
                    dist[i,j] = dist[i,k] + dist[k,j]
}

I will change this soon if nobody protests