Beginners Guide to Arrays
Do you want to store MANY variables in one name? Try Arrays! This Tutorial will Teach you the basics of Creating Arrays! Including MultiDemensional Arrays!
AI
AI Summary: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.
Source Code
<h1>Beginner's Guide to Arrays</h1> <p><hr> <p><h4>Background</h4> <p>Have you wanted to store 300 integers in a variable? like variable d? well now you can with the Beginner's Guide to Arrays! <p><hr> <p><h4>Regular Arrays</h4> <p>Arrays are a way of storing data. instead of using 13 variables to hold 13 different integers you can use one to hold all thirteen! using the following code: <p>dim K(12) as integer <p>That code holds 13 integers in Variable K. Arrays start at 0 so if you wanted to create 300 integers you'd say 'dim K(299) as integer' instead of dim'ing K1 - K300. <p>When Setting Arrays equal to something you use the following Statement: <p>K(1) = 3 <p>This would create part 2 of K equal to 3. You can put any integer equivilant or equal to the number you put inside of the brakets when you dim'ed K. <p><hr> <p><h4>Multi-Demensional Arrays</h4> <p>Multi Demensional Arrays are basically the same as Regular Arrays except for one thing. there are more then 1 dimension. Multi-Dimensional Arrays allow you to create Matrixs or even 7d Tables (Don't ask me what those look like). Multi Dimensional Arrays are used for many things. Score Cards and tables are examples of 2 dimensional arrays and 3d Axis' are a examples of 3 Dimensional Arrays. Multi Dimensional Arrays are dim'ed like so: <p>Dim K(1,1) as integer <p>That creates 4 K's. You can acess the Variables by: <p>K(0,1) = K(1,0) <p>That makes whatever 0,1 on the table is equal to whatever 1,0 is. <p><hr> <p>Thats it for Arrays. Enjoy your stay at PSC! <p><h3>L124RD</h3>
Original Comments (3)
Recovered from Wayback Machine