Computer Science Canada keeping track |
Author: | bucky-lady [ Sat Dec 16, 2006 3:14 pm ] |
Post subject: | keeping track |
hey! so i have to add a variable to keep track of the number of tries it takes to guess the correct answer. how do i do that ? could you help me pretty please ? |
Author: | StealthArcher [ Sat Dec 16, 2006 3:18 pm ] | ||
Post subject: | |||
Every time you run your proc or whatever to get the users guess, and have a variable going to vlaculate something like this:
and run the rest from there. Sorry if im not extremely informative. |
Author: | Clayton [ Sat Dec 16, 2006 6:56 pm ] | ||
Post subject: | |||
Welcome to CompSci, both of you! While here, take a look see at the Turing Walkthrough to try and answer any (and most likely all) of your questions. @StealthArcher: Your code would be better suited as a function:
Check out the Turing Walkthrough if you have any problems understanding this. |
Author: | StealthArcher [ Sat Dec 16, 2006 9:30 pm ] |
Post subject: | |
Nope makes perfect sense to me, i just got to doing functions in class, been using turing only since the beginning of this school year, no previous programming exp of any kind so its a bit difficult to remember all the easy ways to do everything... |