Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Write a program that plays a word game with the user. The program should ask the user to enter the following: . . His or
Write a program that plays a word game with the user. The program should ask the user to enter the following: . . His or her name The name of a city .His or her age . The name of a college A profession .A type of animal A pet's name After the user has entered these items, the program should display the following story, inserting the user's input into the appropriate locations: There once was a person named name who lived in city. At the age of age, name went to college at college. name graduated and went to work as a profession. Then, name adopted a(n) animal named petname. They both lived happily ever afterl Sample Run Enter name: Al Smith Enter city: Brooklyn Enter age: 43 Enter college: School of Hard Knocks Enter profession: Politician. Enter animal: Pitbull Enter pet name: Toodles 4 4 There once was a person named Al Smith who lived in Brooklyn. At the age of 43, Al Smith went to college at School of Hard Knocks. Al Smith graduated and went to work as a Politician. Then, Al Smith adopted a(n) Pitbull named Toodles.. They both lived happily ever after
Step 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