Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Plz can some1 explain the for i: 0..maxx by 20 command 2 me
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
ruscutie




PostPosted: Thu Oct 12, 2006 4:38 pm   Post subject: Plz can some1 explain the for i: 0..maxx by 20 command 2 me

i am doing turing for the first time at school and i don't really get the for i command in graphics. like in the following program wats the use of for i

for i : 0 .. maxx by 20
drawline(maxx-i , 0, maxx, maxy - i, 16)
end for

plz explain it 2 me
thanx
Sponsor
Sponsor
Sponsor
sponsor
Cervantes




PostPosted: Thu Oct 12, 2006 5:54 pm   Post subject: (No subject)

Try running the following code:
code:

for i : 0 .. maxx by 20
    put i
end for

Now you'll see the values that `i' can take on. Then sub those values into your expressions for drawline and see what comes out. Look for patterns.
ruscutie




PostPosted: Thu Oct 12, 2006 6:09 pm   Post subject: (No subject)

thanx
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 3 Posts ]
Jump to:   


Style:  
Search: