This program is getting the user's first name and last name, then displaying it to the...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
This program is getting the user's first name and last name, then displaying it to the user. It isn't working right and we need to make some changes. 1. On Line 5, return the values for firstname and lastname 2. On Line 8, call the display_name function and store its two return values to the two variables being used in the print statement: first_name, last_name 3. Run the code and enter the appropriate values so you match the output under Desired Output. Click Run to check your code. Click Submit to submit your code to your instructor. Redo 1 # Define the subtraction function 2 def display_name(): 3 4 ▶ Run 5 6 7 8 9 10 11 12 Save #Call the Function. Submit firstname input ("Enter your first name: ") lastname input ("Enter your last name: ") # Display Results print("Your name is", first_name, last_name) Your Output: Desired Output: Your name is Mickey Mouse This program is getting the user's first name and last name, then displaying it to the user. It isn't working right and we need to make some changes. 1. On Line 5, return the values for firstname and lastname 2. On Line 8, call the display_name function and store its two return values to the two variables being used in the print statement: first_name, last_name 3. Run the code and enter the appropriate values so you match the output under Desired Output. Click Run to check your code. Click Submit to submit your code to your instructor. Redo 1 # Define the subtraction function 2 def display_name(): 3 4 ▶ Run 5 6 7 8 9 10 11 12 Save #Call the Function. Submit firstname input ("Enter your first name: ") lastname input ("Enter your last name: ") # Display Results print("Your name is", first_name, last_name) Your Output: Desired Output: Your name is Mickey Mouse
Expert Answer:
Answer rating: 100% (QA)
Heres a corrected version that addresses those issues and matches the des... View the full answer
Related Book For
Income Tax Fundamentals 2013
ISBN: 9781285586618
31st Edition
Authors: Gerald E. Whittenburg, Martha Altus Buller, Steven L Gill
Posted Date:
Students also viewed these programming questions
-
5. Write the three thermochemical equations (1) to (3) (from pre-lab lecture) needed to calculate AH for the reaction below. Include AH values for each reaction (HINT: Look at your answers for Q2 and...
-
Carol Harris, Ph.D, CPA, is a single taxpayer and she lives at 674 Yankee Street, Durham, NC 27409. Her Social Security number is 793-52-4335. Carol is an Associate Professor of Accounting at a local...
-
Planning is one of the most important management functions in any business. A front office managers first step in planning should involve determine the departments goals. Planning also includes...
-
Seeking for information of a specific organization then answer following questions: (1) Give a brief introduction of the chosen organization. (2) Explain the type of the chosen organization. What are...
-
The graph shows the influence of the temperature T on the maximum sustainable swimming speed of Coho salmon. (a) What is the meaning of the derivative S'(T)? What are its units? (b) Estimate the...
-
2) Simple Instructions: For each question, assume that the initial value of R1 is 0x0000ffff and the initial value of R2 is 0x00ffff00. What is the value in R3 after each instruction executes? (2...
-
With reference to Exercise 3.25, suppose that three of the spark plugs are defective. In how many ways can 4 spark plugs be selected so that (a) one of the defective plugs is selected; (b) two of the...
-
Lets take our prototypes and some new displays, reports, and forms to create the final user interface, Anna says to Chip. Its about time, isnt it? replies Chip. He was all too aware of the importance...
-
1. List and explain what benefits Mimitos will obtain with the creation of a website and online sales platform.
-
A dynamic vibration absorber is shown in Figure P2.2. This system is representative of many situations involving the vibration of machines containing unbalanced components. The parameters M2 and kl2...
-
How can qualitative research be used to strengthen Nikes image? Which qualitative research technique(s) should be used and why? How can Nike make use of social media in this context?
-
Suppose the value of the S&P 500 stock index is currently 2,000. a. If the 1-year T-bill rate is 3% and the expected dividend yield on the S&P 500 is 2%, what should the 1-year maturity futures price...
-
Financial accounting is the process of a. producing budgets and financial documents for managers. b. producing financial documents for outside investors. c. auditing corporate financial statements....
-
Assume that a company announces an unexpectedly large cash dividend to its shareholders. In an efficient market without information leakage, one might expect: a. An abnormal price change at the...
-
What is the funds standard deviation?
-
A ratio analysis can be used to better compare companies of different sizes. True or False
-
Menus are attached to windows by calling method____________. A) addMenuBar B) setJMenuBar C) setMenu D) addJMenuBar 67. The first argument to method showMessageDialog specifies A) the title B) the...
-
In Problems 1522, find the principal needed now to get each amount; that is, find the present value. To get $750 after 2 years at 2.5% compounded quarterly.
-
The following additional information is available for the Dr. Ivan and Irene Incisor family from Chapters 1-6. On December 12, Irene purchased the building where her store is located. She paid...
-
In June of 2012, Maureen's house is vandalized during a long-term power failure after a hurricane hit the city. The president of the United States declares Maureen's city a disaster area as a result...
-
Diego, age 28, married Dolores, age 27, in 2012. Their salaries for the year amounted to $46,479 and they had interest income of $3,500. Diego and Dolores' deductions for adjusted gross income...
-
Timiri received a diamond ring from her father as a gift on December 25. Her father paid \($6,250\) for the ring three years ago and its fair market value on December 25 is \($5,000.\) Assume her...
-
Arjun died on April 3, Year 4 with a gross estate of \($11,500,000.\) In his will, he left his personal residence to his grandson. Arjun had originally purchased the home for \($172,000.\) Fair...
-
Shaquille received artwork from his grandma as a gift on January 31. Grandma purchased the artwork for \($5,000\) and its fair market value on January 31 is \($8,500.\) What is Shaquilles gain basis...
Study smarter with the SolutionInn App