' Theremino Automation demo program
' Demonstrating the FOR-NEXT statements

Variable Numeric nn1
Variable Numeric nn2
Variable Numeric nn3

nn2 = 11
nn3 = 13

v2 = 8
v3 = 6

For v1 = v2 To v3
	For nn1 = nn2 To nn3
		Beep
		Wait Seconds 0.05
	Next
Next

For nn1 = v3+100 To "v2 + 100 + int(rnd * 8)"
	Beep
	Wait Seconds 0.05
	If nn1 = 25
		Exit
	EndIf
Next

Stop


'WATCH v1
'WATCH nn1
'EXEC nn1 = 25
