Page 1 of 1

Posted: Tue Mar 18, 2003 11:00 pm
by BackupUser
Restored from previous forum. Originally posted by cor.

Are Dim global's etc always placed at the datasection?

Or can I speed it up by doing the following

Code: Select all

DataSection
Dim test.s(100)
For i = 0 To 100
 test(i)="nr" +Str(i)
Next i
EndDataSection


OpenConsole()
For i = 0 To 100
 Print (test(i) )
 PrintN ("")
Next i

Print ("press enter key")
Input() 
CloseConsole()

End

Using Windows 98 SE
Registered Purebasic
--------------------------
C. de Visser
Author of Super Guitar Chord Finder
http://www.ready4music.com
http://www.chordplanet.com

Posted: Wed Mar 19, 2003 12:04 am
by BackupUser
Restored from previous forum. Originally posted by tinman.
Originally posted by cor

Are Dim global's etc always placed at the datasection?
I don't think so. DataSection is only for embedding data into your executable. Arrays and things are allocated from memory when you dim them.


--
I used to be a nihilist but I don't believe in that any more.
(Win98first ed. + all updates, PB3.51, Ed3.53)