Answered step by step
Verified Expert Solution
Question
1 Approved Answer
in Java Your program is to write loops that asks the user to enter information relating to a course they are currently taking - ask
in Java
Your program is to write loops that asks the user to enter information relating to a course they are currently taking - ask for the course number, department name, the number of times it meets in a week, the time the class starts, the instructor name, and the number of students. For each item, check to make sure that what the user enters is actually of the correct type, and if not, use an infinite loop to ask again. So if an integer needs to be entered, make sure an integer is entered, and loop until one actually is. Use next() to remove unwanted words when users do not type in a word of the correct type. When a user types in an unwanted word (e.g. the wrong type) print an error message saying that you need input of integer type or string type, etcStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started