Criteria The program asks for user input to dictate the story The program asks the user...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Criteria The program asks for user input to dictate the story The program asks the user to pick from three options at the first branch The program asks the user to pick from two options at the second branch The program uses if-else-if statements The program uses nested conditional statements The program includes appropriate code comments TOTAL Points 5 pts 5 pts 5 pts 5 pts 5 pts 5 pts 30 pts My Story Assignment My Story Coding Assignment Using the MyStory program in the right panel, your task is to write and test a program that provides an interactive story. These are the requirements: • You must ask the user to provide input and those responses dictate the story • You must use if-else-if statements and nested statements • The story should allow the user to pick from three options at the first branch and then choose from two options at the second branch Be creative! Whenever you are ready to compile and test your program, click the Compile and Run button. COMPILE AND RUN Project container was stopped by inactivity timeout, please MyStory.java 1234 5 6 7 8 9 10 11 12 13 14 15 16 17 import java.util.Scanner; public class MyStory { public static void main(String[] arg) { /* *The Scanner class is used for reading in data to your program. */ Scanner keyboard = new Scanner (System.in); //Copy and paste this code when you want the user to make a decision //By selecting a number System.out.print("Enter your choice: "); int choice = keyboard.nextInt(); //Write your code below: Criteria The program asks for user input to dictate the story The program asks the user to pick from three options at the first branch The program asks the user to pick from two options at the second branch The program uses if-else-if statements The program uses nested conditional statements The program includes appropriate code comments TOTAL Points 5 pts 5 pts 5 pts 5 pts 5 pts 5 pts 30 pts My Story Assignment My Story Coding Assignment Using the MyStory program in the right panel, your task is to write and test a program that provides an interactive story. These are the requirements: • You must ask the user to provide input and those responses dictate the story • You must use if-else-if statements and nested statements • The story should allow the user to pick from three options at the first branch and then choose from two options at the second branch Be creative! Whenever you are ready to compile and test your program, click the Compile and Run button. COMPILE AND RUN Project container was stopped by inactivity timeout, please MyStory.java 1234 5 6 7 8 9 10 11 12 13 14 15 16 17 import java.util.Scanner; public class MyStory { public static void main(String[] arg) { /* *The Scanner class is used for reading in data to your program. */ Scanner keyboard = new Scanner (System.in); //Copy and paste this code when you want the user to make a decision //By selecting a number System.out.print("Enter your choice: "); int choice = keyboard.nextInt(); //Write your code below:
Expert Answer:
Answer rating: 100% (QA)
Below is a simple interactive story program that follows the specified criteria java import javautilScanner public class MyStory public static void ma... View the full answer
Related Book For
Auditing and Assurance services an integrated approach
ISBN: 978-0132575959
14th Edition
Authors: Alvin a. arens, Randal j. elder, Mark s. Beasley
Posted Date:
Students also viewed these programming questions
-
can someone solve this Modern workstations typically have memory systems that incorporate two or three levels of caching. Explain why they are designed like this. [4 marks] In order to investigate...
-
Question 4. The brain of leech lies above the: a) Mouth b) Buccal Cavity c) Pharynx d) Crop
-
A 0.14-kg pinecone falls 16 m to the ground, where it lands with a speed of 13 m/s. (a) With what speed would the pinecone have landed if there had been no air resistance? (b) Did air resistance do...
-
Astroid Find the total length of the graph of the astroid x 2/3 + y 2/3 = 4. -6 8 2 -2 -6 -8 y x2/3 + y2/3=4 2 68 X
-
John and Jennifer Margeson entered into a contract to sell a weight-loss franchise business called Inches-A-Weigh to Theresa Artis. The parties memorialized their agreement in an Asset Purchase...
-
RiverHawk Expeditions provides guided tours in scenic mountainous areas. After the first 11 months of operations in 2015, RiverHawk has the following account balances. The following transactions...
-
1. Using Fig 2.16 calculate S max of solar constant (irradiance) corresponding to the maximum irradiance over the 25 years presented on the graph (round your answer to 4 digits). 2. Calculate RF max...
-
On January 1, Boston Company completed the following transactions (use a 7% annual interest rate for all transactions): ( EV of $1. PV of $1. EVA of $1. and PVA of $1) (Use the appropriate factor(s)...
-
Use NexisUni to complete. For each of the following cases identify the full names of the parties, explain the components of each citation (i.e., in what print source is each decision's text located...
-
3. Big O running time of the following program fragments. (a) for (i =0; i < n; i++) (b) } for (j = 0; j
-
How far should a spring with a spring constant of 250 N/m be stretched in order to store 40.0 J of energy?
-
what technique do you use to prevent one attribute from dominating the others?
-
Describe the Processor and VMM's behavior when a guest VM executed "HLT"?
-
What is f "(x) if f(x) = xcos(x)?
-
The WorldCom scandal was one of the most shocking and widespread fraud to rock Wall Street in generations As an accounting student, you are required to search for the WorldCom Scandal. What were the...
-
The Adjusted Trial Balance columns of a 10-column work sheet for Webber Co. follow. Complete the work sheet by extending the account balances into the appropriate financial statement columns and by...
-
What should the audit team consider in its planning discussion about fraud risks?
-
Explain what is meant by an imprest payroll account. What is its purpose as a control over payroll?
-
Distinguish the auditor's responsibility for testing controls in an integrated audit of a public company from the responsibility to test controls in an audit of a nonpublic company.
-
Prove that the angular momentum operator \(L_{z}\) generates rotations around the \(z\)-axis.
-
Show that for real numbers \(\alpha, \beta\), and \(\delta\) the matrices form a group under matrix multiplication. Show that the matrices \(G\) with \(\alpha=\beta=0\) form an invariant subgroup of...
-
Show that the quotient group of the 4-group \(\mathrm{D}_{2}\) defined in Problem 2.9 is \(\mathrm{C}_{2}\).
Study smarter with the SolutionInn App