
	#ļ϶Dove.exeͼϼ

	#C
	#ָ֧

ver  #ʹver鿴ǰDove Script汾
pause
cls

set norterr	#ʱжϳ
print "ʵһʾ"
const PI=3.1415	#PIǳ
print "ֵᱨˡset norterr򲻻˳ִ"
PI=3		#ֵ
print "PI=" &PI
pause		#ͣ

bb=2
cc=3
dd=4
newline

DIF = ( PI + bb ) * cc / dd - 6.3 * 7.33 + 6 % 4
print "DIF= " & DIF
newline

r=3
print "PI*(r^2) = " & (PI*r*r) & " ǰ뾶Ϊ3Բ"

print "PI+1 == 4.1415 ֵ" & (PI+1==4.1415)

pause
#exit		#ʹexitԶģʽ
cls


	#while example
print "ʵѭжʾ"
a=0
b=0
c=1
while a<3
	print "Wѭ" & a+1 & ""
	a=a+1
	while b<=3
		print "    Nѭ" & b+1 & ""
		b=b+1
		if b>2
			break
		endif
	endw
	if c==1
		newline
		print "ready to continue!"
		newline
		c=0
		a=0
		b=0
		continue
	endif
	b=0
endw
pause
cls


	#graph example
set rterr		#ʱԶֹ
print "ʵͼ"
use graph			#̬װgraph⣨ͼ
	graph G
	G.addVertex a,b,c,d,e		#
	G.addDoubleEdge a,b,100,b,c,200,c,d,300,d,e,400,e,a,500
#

	print "	Gͼ£"
	print "		㣺 a,b,c,d,e"
	print "		˫ߣa-b:100, b-c:200, c-d:300, d-e:400, e-a:500"

	print "ͨ·"
	G.minWResult
	newline
	
	G.addVertex f
	G.addEdge f,a,200
	print "һfӵf-a:200"

	print "	acǷֱӣ"
	G.isConnected a,c,true
	newline

	print "	acǷͨ"
	G.isConnected a,c,false
	newline
	
	print "	afǷͨ"
	G.isConnected a,f,false
	newline

	print "	faǷͨ"
	G.isConnected f,a,false
	newline

	print "	ae·"
	G.shortestPath a,e
	newline

	print "	af·"
	G.shortestPath a,f
	newline
	
pause
un graph


exit