Hi Rob, the linkage is set up at compile time. But the problem was the placement of at.
at needs to come before as, when the type is specified on the right
dim m at #m as single
dim n at #n as single
some other possibilities:
dim m at #m, n at #n as single
dim as single m at #m, n at #n
single m at #m, n at #n
' Empty thinBasic CONSOLE file template
Uses "Console" , "oxygen"
Dim m(33) , n(33) As Single
Dim s As String
s="
dim m at #m as single
dim n at #n as single
'
'dim m at #m, n at #n as single
'
'dim as single m at #m, n at #n
'
'single m at #m, n at #n
'
dim i as integer
dim j , dz as single
dz=1/33
For i=0 To 32
m(i+1)=i*dz
Next
cr=chr(13,10)
tab=chr(9)
pr=""
i=1
For j=0 To 1-dz step dz
pr+= "Iteration #"+str(i)+" result : "+str(j) cr
n(i)=j
i++
Next
print pr
"
O2_Basic s
If O2_Errno Then
MsgBox 0, O2_Error
Stop
End If
O2_Exec
dim i as long
For i=1 to 33
printl "Iteration #"+str$(i)+" result : "+str$(n(i))
Next
WaitKey
Bookmarks