It worked! Thx a lot! =) Now I can input my name and age, then it say's if im too young or i'm ready to vote. =)
thanks for the help everyone!
No, no, no, NO! Read the other posts. You do NOT want to throw the exception from main(). Don't even consider that an option. Yes, I know that it worked but it is NOT a habit you want to get into.
Add a try{} catch () {} block around the code that is using the reader as other posters have indicated.
Moderator
Featured Poster
Reputation Points: 3239
Solved Threads: 838
Posting Genius
Offline 6,756 posts
since May 2007