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
-
1.To parse a string that might contain a currency value such as $1,234.56, you should pass the Parse or TryParse method which of the following values? a.NumberStyles.AllowCurrencySymbol...
-
Sandhill Company purchased a large piece of equipment on October 1, 2023. The following information relating to the equipment was gathered at the end of October: Price Credit terms $90,000 2/10, n/30...
-
Known liabilities of uncertain amounts should be a. estimated and accrued when they occur. b. ignored; record them when they are paid. C. reported on the income statement. d. described in the notes...
-
On January 4, 2013, Runyan Bakery paid $324 million for 10 million shares of Lavery Labeling Company common stock . The investment represents a 30% interest in the net assets of Lavery and gave...
-
5. Charlie's clinic began tracking its patient services for the last six months. Using the data, they would like to forecast for the next six months. Summarize three to five key points for Charlie's...
-
Eta Corporation approaches Lily White, the CEO and sole shareholder of MuCo, regarding the acquisition of MuCo's cat toy division assets (worth $1.3 million). As selling the assets would create a...
-
following are the static budget planned and actual sales for the three products produced by best company contribution margin actual units static budget units alpha $300 250,000 450,000 beta $450...
-
Alex Corporation provides the following information for the year: Net sales Operating income Average assets Target rate of return Division A $410,000 102,500 670,000 15% Calculate the residual income...
-
How do theories of organizational change and resistance inform strategic initiatives aimed at fostering organizational agility and adaptation in turbulent environments ?
-
(a) What are the three requirements for successful recursion in C++? [3 marks] (b) Please explain the advantages and disadvantages of using recursion instead of an iterative approach. [2 marks] (c)...
-
Balboa Partnership is owned by the following: 2 5 % by Ann 1 0 % by Bill ( Ann ' s son ) 1 0 % by Charles ( Ann ' s brother ) 2 5 % by Dagwood ( unrelated to Ann ) 3 0 % by Acme Corporation ( owned...
-
Miami Solar manufactures solar panels for industrial use. The company budgets production of 5,400 units (solar panels) in July and 5,400 units in August. QS 20-11 (Algo) Manufacturing: Factory...
-
Define and give examples of ascribed status, achieved status,master status, role conflic,t and role strain
-
7 A 29-year-old, previously healthy man suddenly collapses at a party where legal and illicit drugs are being used. Enroute to the hospital, he requires resuscitation with defibrillation to establish...
-
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.
-
Chef's Catering completed the following selected transactions during May 2020: Required 1. Show whether each transaction would be handled as a revenue or an expense using both the cash basis and...
-
Consider the unadjusted trial balance of Burrows Landscaping at December 31, 2020, and the related month-end adjustment data: The following adjustments need to be made on December 31 before the...
-
Gonzales Sales and Service completed the following transactions during 2020: Required 1. Journalize these entries by debiting an asset account for Prepaid Rent and by crediting a liability account...
Study smarter with the SolutionInn App