View Single Post
Old 10-09-2012, 12:30 PM   PM User | #8
tbmtbm
New to the CF scene

 
Join Date: Sep 2012
Posts: 7
Thanks: 5
Thanked 0 Times in 0 Posts
tbmtbm is an unknown quantity at this point
Quote:
Originally Posted by Philip M View Post
It is for more user-friendly to test for the first letter of the reposnse "s" or "p" (case insensitive) rather than reject the input, display an error message, and require the answer to be entered again.
I thought that too, but my professor specifically wanted an error message. Probably to teach us error handling.

The code that shya did works for the first switch, but not the second. If I put in "Stars", or "S", and then a number, the correct answer comes up.

If I put "Planets" or "P", then a number, however, nothing comes up. I can't figure out why.
tbmtbm is offline   Reply With Quote