vj1391 &aelig;ƒ&sup3;&egrave;&para;Š&ccedil;‹&plusmn;&ccedil;š„&aring;&deg;&aelig;‰

# Vj1391 æƒ³è¶Šç‹±çš„å°æ‰

This preview shows pages 1–2. Sign up to view the full content.

//±ÉÈËµÄ·½·¨ //spfa ¸Ä //dist [ i ] = max( min( dist [ j ] , g [ j , i ] ) ) g[j,i]>0 / //±ÉÈËµÄÎÊÌâ //ÓÃÑ»·¶ÓÁÐ mod ·¨ ÅÐ¶ÏÌõ¼þÊÇ f<>r » uses math; const maxn=2000; maxp=100000; var n,f,r:integer; dist,q:array[0. .maxn] of longint; g:array[0. .maxn,0. .maxn] of longint; v:array[0. .maxn] of boolean; procedure init; var x,y,z:longint; begin readln(n); read(x,y,z); while x<>0 do begin g[x,y]:=z; read(x,y,z); end; end; procedure spfa;

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

## This note was uploaded on 02/21/2011 for the course CS 001 taught by Professor 001 during the Spring '11 term at Shandong University.

### Page1 / 2

Vj1391 æƒ³è¶Šç‹±çš„å°æ‰

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online