View Single Post
Old 06-05-2006, 05:08 PM   #3
dplax
Jack Burton
 

Join Date: July 19, 2003
Location: an expat living in France
Age: 38
Posts: 5,577
To place an element into an array you should use:

code:
array [i][j]...[n]=datatoinput
[/QUOTE]where the first [] represents the first dimension, the second the second, etc.


The syntax for a for loop is:

code:
for (commandToExecuteAtStart; exitCondition; commandToExecuteAtEachIteration){}
[/QUOTE]and then you would put the instructions you want to execute inside the {}. Two examples would be:

code:
for (i=0; i<n; i++)
[/QUOTE], which does n iterations
code:
for ( ; ; )
[/QUOTE], which is an infinite for loop.


Hope that helps.
dplax is offline   Reply With Quote