subject
Engineering, 21.02.2020 20:20 neariah24

Artificial Intelligence elements in programming. Creating different outputs based on user input.

Ask a series of questions and based on the answer, create an adventure or story.

Welcome the use and let them know what is about to happen.
Use JOptionPane for input and output.
Use String. format() for the output.
Ask the user a series of questions. 10-15 questions with each answer being able to generate 1-3 sentences will build a nice size story.
Build a story for that user to read.
The story should be different based on the answers For example if the computer asks "How are you today?" the story takes a different turn for "Happy" that it would for "SAD"
Allow the user to do the story again without leaving the program. They should get different results with different answers.
Look at giving one or two answers with randomized results. (the same answer gets a different result)
Print the story for the user to see.
When they are ready to leave, thank the user for using the program.
The learning goal for this exercise is to use switch statements and loops to create a user input generated story.

Use at least one loop and three switch statements. You will likely need more. Some decisions can be satisfied with IF statements.
Use the java command to evaluate the results of your code.
IN JAVA

ansver
Answers: 3

Another question on Engineering

question
Engineering, 03.07.2019 23:20
Two technicians are discussing the intake air temperature (iat) sensor. technician a says that the computer uses the iat sensor as a backup to the engine coolant temperature (ect) sensor. technician b says that the powertrain control module (pcm) will subtract the calculated amount of fuel if the air measures hot. who is correct
Answers: 3
question
Engineering, 04.07.2019 18:20
Select any two (2) areas of applications of chain-drive. (clo4) a)-permanent lubrication necessary b)-hydraulic forklift truck operation c)-rigging and heavy moving materials d)-relatively high maintenance costs e)-costlier than belt drives
Answers: 2
question
Engineering, 04.07.2019 18:20
Find the minimum film thickness for a journal bearing with the data below. shaft diameter, d-50 mm, clearance ratio, cdratio? 0.001, shaft speed, n 2000 rpm; bearing length. i 200 mm; eccentricity ration, ? -0.55. ( note, cdratio-ca/d) the minimum film thickness is um
Answers: 2
question
Engineering, 04.07.2019 19:10
What is a monomer? how do they form a ploymer from the view point of chemical bonding?
Answers: 1
You know the right answer?
Artificial Intelligence elements in programming. Creating different outputs based on user input.
Questions
question
Social Studies, 19.08.2019 19:40
question
Mathematics, 19.08.2019 19:40
question
Mathematics, 19.08.2019 19:40
Questions on the website: 13722361