Question: Please Answer in JAVA You will be writing a program that simulates the magic 8 ball. You will prompt the user to enter a question
Please Answer in JAVA
You will be writing a program that simulates the magic 8 ball. You will prompt the user to enter a question and the software will produce a reply. Replies will be randomly selected from a series of replies coded in the software.
You must use:
1. A random number generator.
2. The switch statement for the replies.
3. A while(true) loop so that the user is prompted for more questions. Do-While is fine, too.
4. Passing parameters between main and other methods.
5. At least 3 methods: main, an input method, and an output method (the method to produce the replies)
There is no correlation between the user's question and program's response. Make sure your responses have a Computer Science flavor. For instance, if I were to make a Magic 8 Ball for statisticians one of my responses might be That is not statistically significant. Basically, create some geek-type responses like Out of memory, please try again later or My vast database of human intelligence indicates the answer is...no. Also, the minimum number of responses are as follows: 3 positive responses 3 neutral responses 3 negative responses but you can have more for each if you would like. Get creative and have fun with this one.
Input Format A string of the user's question.
Output Format A string of the computer's response.
Sample Input Enter question: Will Morpheus ever save me from the Matrix?
Sample Output Our robot overlords say, no.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
