view Bison-Flex/BasicCompiler-MemoryBase/test.txt @ 0:db40c85cad7a default tip

upload sample source
author nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
date Mon, 09 May 2011 03:11:59 +0900
parents
children
line wrap: on
line source

'コメントテスト
rem これもコメント

' 二重ループのテスト
for i=1 to 3
	for j=1 to 3
		print i, j
	next
next


' 代入とrand関数のテスト
a = rand(10)
b = rand(10)

' ある程度の計算式
c = a + b * 10 / 3

print a, b, c

' if文
if a == b then
	a = 100
else
	b = 100
endif

print a, b

' for文
for i=1 to 10
	a = a + 1
next

print a, b

' while文
while a != 0
	a = a - 1
wend

print a, b

end