alice-teacher Number Variables - Integer Only?
Michael Bauer
mbauer at hawaii.edu
Fri Apr 8 01:29:51 EDT 2011
Is there a way to specify that number variables store integers rather than real numbers. If you are using the textbook by Wanda, Steve & Randy, I am looking at the timer example in chapter ten. I want the time to display an integer, rather than a real number (eg., 10 instead of 10.0). I can get the text to display an integer initially with no problem. When the loop starts iterating and the variable gets incremented/decremented, then the passing the variable to the "set text to" method causes it to display a real number where I'd rather just see an integer.
If you think of a scorekeeper rather than a timer, a game would increment a score everytime something is successful. I'd like the score to display without the decimal place.
Thanks for your help!
Mike Bauer.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.andrew.cmu.edu/mailman/private/alice-teachers/attachments/20110407/b6eb706c/attachment.html
More information about the alice-teachers
mailing list