Question

= Syst x Grades for Lewis Dickerson: [Sum X MindTap - Cengage Learning X Python Programming | Facebook X war Python: cengage.

how do you insert a print command that changes with what name you type?

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Source Code:

myinfo.py - C:/Users/Kumar Reddi/Desktop/myinfo.py (3.8.2) File Edit Format Run Options Window Help #read name from the user

Output:

IT Python 3.8.2 Shell File Edit Shell Debug Options Window Help Python 3.8.2 (tags/v3.8.2:7b3ab59, Feb 25 2020, 22:45:29) [MS

Code in text format (See above images of code for indentation):

#read name from the user
name=input("Enter your name: ")
#read age from the user
age=int(input("Enter your age: "))
#new line
print()
#print command that changes with what name you type
print(name," is ",age," years old.")

Add a comment
Know the answer?
Add Answer to:
how do you insert a print command that changes with what name you type? = Syst...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • byst x Grades for Lewis Dickerson: (Sun X MindTap - Cengage Learning х Python Programming |...

    byst x Grades for Lewis Dickerson: (Sun X MindTap - Cengage Learning х Python Programming | Facebook x war Python: Inp Cengage.com/static/nb/ui/evo/index.html?deploymentid=58296224090012788153144858955&eISBN=9781337560115&id=811000539&snap CENGAGE MINDTAP Programming Exercise 1.7 Instructions myinfo.py ols V- 1 name= input 2 age = int(in 3 print("Alex Write and test a program that accepts the user's name (as text) and age (as a number) as input. . 4 The program should output a sentence containing the user's name and age. S An example of the program input...

  • the problem is in the first photo but when i try to code the problem and...

    the problem is in the first photo but when i try to code the problem and get the solution i get a 0% am o doing something wrong? need help Edit View History Bookmarks People Tab Window Help х Mind Tap - Cengage MindTap - Cengage Learning arse Modules: Summer 202 X ng.cengage.com/static/nb/ui/evo/index.html?deploymentid=5829622314511297 WeteransUnited... HOA PAYMENT M JOHNNY EMAIL: fi... M KATIE EMAIL: flor... EDDE CENGAGE MINDTAP Programming Exercise 2.3 Instructions Study Tools fivestar.py 1 new=int(input 2 oldvint(input 3 total=(new...

  • 5 5 - Parallel Arrays in Python Mind Tap - Cengage Lea x + V A...

    5 5 - Parallel Arrays in Python Mind Tap - Cengage Lea x + V A https//ng.cengage.com/static/nb/ui/evo/index.html?deploymentid=5745322406056533358933471518eISBN=9781337274509&id=586434 145&snapshotld: L x ... € → O 1 » CENGAGE MINDTAP Q Search this course x Parallel Arrays in Python D Parallel Lists Jumpinjive.py + > Terminal + 1 # Jumpin Java.py - This program looks up and prints the names and prices of coffee orders. 2 # Input: Interactive 3 # Output: Name and price of coffee orders or error message if...

  • Python assignment:  Write a program that asks for the user's age. Based on their response print "You...

    Python assignment:  Write a program that asks for the user's age. Based on their response print "You can vote" (18 years old or older) or "You can't vote" and also whether or not he/she is a senior citizen (over 64). If senior citizen print "You're a Senior Citizen...you deserve two votes"!   Use the Idle editor and don't forget the .py extension. Good luck.          Your python program will be graded on the following:     Execution of the program gives the correct...

  • You will create a new project. Type in the following program and run it to produce...

    You will create a new project. Type in the following program and run it to produce the output for the program. Good practice in writing a program in any language, including Python, is to add comments for each line and state clearly what is the program input and output. Your program must include comments, so a reader will know exactly what you are trying to do in each line of code and allow for easy maintenance. Beginning a line with...

  • Question 1 The code used to output messages to the screen begins with run # print...

    Question 1 The code used to output messages to the screen begins with run # print output Flag this Question Question 2 The code used to begin a comment in the Python program source code is # Hello * Comment Flag this Question Question 3 A variable name is like a(n) input typed on a keyboard address in computer memory where values can be stored output to a computer screen value assigned to an address in computer memory Flag this...

  • Opening Files and Performing File Input 1 V/ Flowers.cpp This program reads nanes of flowers and ...

    Opening Files and Performing File Input in C++ Opening Files and Performing File Input 1 V/ Flowers.cpp This program reads nanes of flowers and whether they are grown in shade or sun from an input 2 file and prints the information to the user's screen. 3 Input: flowers.dat 41 Output: Names of flowers and the words sun or shade Summary In this lab, you open a file and read input from that file in a prewritten C++ program. The program...

  • write codes and give detailed explanation of how to execute. What you need to turn in:...

    write codes and give detailed explanation of how to execute. What you need to turn in: You will need to include an electronic copy of your report (standalone) and source code (zipped) of your programs. All programming files (source code) must be put in a zipped folder named "labl-name," where "name" is your last name. Submit the zipped folder on the assignment page in Canvas; submit the report separately (not inside the zipped folder) as a Microsoft Word or PDF...

  • write programs with detailed instructions on how to execute. code is java What you need to...

    write programs with detailed instructions on how to execute. code is java What you need to turn in: You will need to include an electronic copy of your report (standalone) and source code (zipped) of your programs. All programming files (source code) must be put in a zipped folder named "labl-name," where "name" is your last name. Submit the zipped folder on the assignment page in Canvas; submit the report separately (not inside the zipped folder) as a Microsoft Word...

  • can someone assist me and tell me what I'm missing. I managed to get it this...

    can someone assist me and tell me what I'm missing. I managed to get it this far but still missing two parts to complete it. CENGAGE MINDTAP Programming Exercise 6-4 Tasks main.cpp + 1 #include <iostream r with successful Uses piand 2 #include <cnath> output 5,00 out of 10.00 3 using nanespace std; 4 5 const double PI = 3.1419; 2 out of 4 checks passed. Review 6 the results below for more details. 7 int main() 8 ( Checks...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT