Answered step by step
Verified Expert Solution
Question
1 Approved Answer
*JAVA PROGRAM* Create a one file program that prompts the user a minimum of five times to indicate their preference between two unique choices. Possible
*JAVA PROGRAM*
Create a one file program that prompts the user a minimum of five times to indicate their preference between two unique choices. Possible choices include but are not limited to: mild or spicy tea or coffee breakfast or brunch summer or winter paper or plastic Prompt the user to enter 0 or 1: where 0 is for the choice on the left and 1 is for the choice on the right. Given this structure, the user will end with a score of O through 5. If the score is less than 3, exactly 3, or greater than 3, print messages to the user indicating something about their personality based on the choices they've made. For example: Score less than 3: "You prefer life to be calm and organized" Score greater than 3: "You prefer life to be spontaneous and active" Score exactly 3: "You prefer a good balance in life 11 Prompt the user to enter 0 or 1: where 0 is for the choice on the left and 1 is for the choice on the right. Given this structure, the user will end with a score of O through 5. If the score is less than 3, exactly 3, or greater than 3, print messages to the user indicating something about their personality based on the choices they've made. For example: Score less than 3: "You prefer life to be calm and organized" Score greater than 3: "You prefer life to be spontaneous and active" Score exactly 3: "You prefer a good balance in life." Try to organize your choices on the left and right for the user so that the resulting message seems plausible. After the score and message are printed, ask the user if they want to run the program again. Minimum Requirements This program should include the following: A Main class with a package statement with edu.wctc A main() method and and minimum of one additional method related to the program that is used by the main() method A String array to hold the choice prompts An int array that has the same size as the String array to hold the user's input Loops to handle repeating behaviors (question prompts, run the program again option, etc.) The use of a boolean variable All behavior as indicated in the Program OutlineStep 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