Posted: Tue Dec 10, 2002 10:02 pm Post subject: kill the goto
i know but i relay relay relay have isuses ageasted goto, it is relay just my opiean. but i also think that it makes you look like a poor porgamer if you uses it too much in a progame, it just is not neacery.
well w/e. i just hope it is not in turing
Computer Science CanadaHelp with programming in C, C++, Java, PHP, Ruby, Turing, VB and more!
Posted: Wed Dec 11, 2002 3:53 pm Post subject: (No subject)
Well, I'm only using it because it takes quite a while to test my program, and it's kinda annoying going through the same processes over and over again
Posted: Wed Dec 11, 2002 4:59 pm Post subject: (No subject)
why not just comment it out then?
highlight what you don't want, then go to Edit -> Comment (i think)
Posted: Wed Dec 11, 2002 7:52 pm Post subject: (No subject)
Okay, another problem, when I try to retrieve the data using the get statement, most of it loads, except one is saying "Invalid integer input". I checked it out, and it turns out that the value that it's trying to load is a 0. Will that cause any problems with my loading, or is there something wrong with my code?
EDIT: Okay, it's not something wrong with my code, because I cut out the code that loads the variable with 0's stored as them, and it works fine. Now all I need to know is how to get Turing to load all the variables, even if they are zeros.
Also, one more thing, I want the user to enter a normal number in certain parts of the game. Is there a code or something that converts all decimal numbers to integers so that the program doesn't crash when a real number is inputted where an integer should be?
Posted: Wed Dec 11, 2002 8:18 pm Post subject: (No subject)
is it 0(Zero) or NULL ? cuz they are different.
Though I donno, maybe its the way you read it or something. 0 is an integer
Yes, there're 3 ways you can change real to integer.
all 3 round the real value and return integer. Ceil always rounds up and floor always rounds down.