Student Value Edition for Starting Out with Python (3rd Edition)
3rd Edition
ISBN: 9780133848496
Author: Tony Gaddis
Publisher: PEARSON
expand_more
expand_more
format_list_bulleted
Textbook Question
Chapter 2, Problem 1AW
Write Python code that prompts the user to enter his or her height and assigns the user's input to a variable named height.
Expert Solution & Answer
Learn your wayIncludes step-by-step video
schedule03:14
Students have asked these similar questions
Python Assignment Lab 3-
1. Prompt the user to enter two integers x,y and then print the value of x2 + y2 in output.
A retail company must file a monthly sales tax report listing the total sales for the month and the amount of state and county sales tax collected. The state sales tax rate is 4 percent and the county sales tax rate is 2 percent. Write a program that asks the user to enter the total sales for the month in python.
1- Write a Python program that keeps a number from the user (between 1 and 7) and displays the name of the weekday.
Example :
Input number: 3
Output :
Wednesday
Chapter 2 Solutions
Student Value Edition for Starting Out with Python (3rd Edition)
Ch. 2.1 - Who is a programmers customer?Ch. 2.1 - What is a software requirement?Ch. 2.1 - What is an algorithm?Ch. 2.1 - What is pseudocode?Ch. 2.1 - Prob. 5CPCh. 2.1 - Prob. 6CPCh. 2.3 - Write a statement that displays your name.Ch. 2.3 - Write a statement that displays the following...Ch. 2.3 - Write a statement that displays the following...Ch. 2.5 - Prob. 10CP
Ch. 2.5 - Which of the following are illegal variable names...Ch. 2.5 - Prob. 12CPCh. 2.5 - Is the following assignment statement valid or...Ch. 2.5 - Prob. 14CPCh. 2.5 - Look at the following assignment statements:...Ch. 2.5 - What will be displayed by the following program?...Ch. 2.6 - You need the user of a program to enter a...Ch. 2.6 - Prob. 18CPCh. 2.7 - Prob. 19CPCh. 2.7 - Prob. 20CPCh. 2.7 - Prob. 21CPCh. 2 - A ______ error does not prevent the program from...Ch. 2 - Prob. 2MCCh. 2 - A(n) __________ is a set of well-defined logical...Ch. 2 - An Informal language that has no syntax rules and...Ch. 2 - A _______ is a diagram that graphically depicts...Ch. 2 - A ______ is a sequence of characters. a. char...Ch. 2 - Prob. 7MCCh. 2 - Prob. 8MCCh. 2 - A string literal in Python must be enclosed in...Ch. 2 - Prob. 10MCCh. 2 - A(n) __________ makes a variable reference a value...Ch. 2 - This symbol marks the beginning of a comment in...Ch. 2 - Which of the following statements will cause an...Ch. 2 - In the expression 12 + 7, the values on the right...Ch. 2 - This operator performs integer division. a. // b....Ch. 2 - This is an operator that raises a number to a...Ch. 2 - This operator performs division, but instead of...Ch. 2 - Prob. 18MCCh. 2 - Which built-in function can be used to read input...Ch. 2 - Prob. 20MCCh. 2 - Programmers must be careful not to make syntax...Ch. 2 - In a math expression, multiplication and division...Ch. 2 - Variable names can have spaces in them.Ch. 2 - In Python, the first character of a variable name...Ch. 2 - If you print a variable that has not been assigned...Ch. 2 - What does a professional programmer usually do...Ch. 2 - What is pseudocode?Ch. 2 - Computer programs typically perform what three...Ch. 2 - If a math expression adds a float to an int, what...Ch. 2 - What is the difference between floating-point...Ch. 2 - Write Python code that prompts the user to enter...Ch. 2 - Write Python code that prompts the user to enter...Ch. 2 - Write assignment statements that perform the...Ch. 2 - Assume the variables result, w, x, y, and z are...Ch. 2 - Write a Python statement that assigns the sum of...Ch. 2 - Write a Python statement that subtracts the...Ch. 2 - Write a Python statement that multiplies the...Ch. 2 - Prob. 8AWCh. 2 - What would the following display? num = 99 num = 5...Ch. 2 - Assume the variable sales references a float...Ch. 2 - Assume the following statement has been executed:...Ch. 2 - What will the following statement display?...Ch. 2 - Personal Information Write a program that displays...Ch. 2 - Sales Prediction A company has determined that its...Ch. 2 - Land Calculation One acre of land is equivalent to...Ch. 2 - Total Purchase A customer in a store is purchasing...Ch. 2 - Distance Traveled Assuming there are no accidents...Ch. 2 - Sales Tax Write a program that will ask the user...Ch. 2 - Miles-per-Gallon A car's miles-per-gallon (MPG)...Ch. 2 - Tip, Tax, and Total Write a program that...Ch. 2 - Celsius to Fahrenheit Temperature Converter Write...Ch. 2 - Ingredient Adjuster A cookie recipe calls for the...Ch. 2 - Male and Female Percentages Write a program that...Ch. 2 - Stock Transaction Program Last month, Joe...
Additional Engineering Textbook Solutions
Find more solutions based on key concepts
In what sense are data structures such as arrays, lists, stacks, queues, and trees abstractions?
Computer Science: An Overview (13th Edition) (What's New in Computer Science)
The following program skeleton asks for an angle in degrees and converts it to radians. The formatting of the f...
Starting Out with C++ from Control Structures to Objects (9th Edition)
State the order of evaluation of the operators in each of the following C statements and show the value of x af...
C How to Program (8th Edition)
How many characters are in each of the following character and string constants? a.\n b.n c.Mary d.M e.Mary\n
Problem Solving with C++ (9th Edition)
Explain the problems that denormalized tables may have for insert, update, and delete actions.
Database Concepts (7th Edition)
True or False: A superclass has a member with package access. A class that is outside the superclasss package b...
Starting Out with Java: Early Objects (6th Edition)
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- Programming Language: Python Create a program that will accept a value in feet and output the corresponding length in inches. Note: 12 inches = 1 footarrow_forwardPython code: Example output: Homework: 89 Test1: 77 Test2: 66 Final: 92 Average score: … I want to ask the user if they want to drop the lowest score. If the user says yes, drop the lowest score and print the new average score. Could you provide the code. Thanks!arrow_forwardProgramming Language: Python 5. Create a program that would input the value of the Radius of a Circle and output the Diameter, Circumference, and Area of a Circle. Pi = 3.1416. Formula: Diameter = 2 * Radius Circumference = 2 * Pi * Radius Area = Pi * Radius * Radiusarrow_forward
- In Python Write a program that allows the user to type in a phrase and then outputs the acronym for that phrase. Note: The acronym should be all uppercase, even if the words in the phrase are not capitalized.arrow_forwardDesign a program that calculates the bonus for each employee. The bonus isbased on the salary.Salary Percentage for bonus$30,000 or less 5%Over $30,000 but not more than $50,000 4%Over $50,000 but not more than $100,000 2%Over $100,000 1%a) Writing pseudocodeb) Writing Python code (please submit .py file)arrow_forward(This needs to be coded using Python) Write and test a program that accepts the user’s name (as text) and age (as a number) as input. The program should output a sentence containing the user’s name and age. An example of the program input and output is shown below:Enter your name: Alex Enter your age: 23 Alex is 23 years old.arrow_forward
- In Python the first character of a variable name cannot be a number.True or Falsearrow_forwardIn Python, Assuming minors are younger than 13 and adults are older than 19, write a program that prompts the user to enter his/her age and then reports whether the user is a minor, teenager, or adult Plan each program by writing pseudocode. Write all of your pseudocode as comments immediately after your name and 2380093 Add more comments as needed in each program to explain your code. Choose descriptive variable names in all programs. Currency format. There should be no space between the $ sign and the first digit. See sep on page 66 to cancel the space automatically added when print items are separated by commas. Display commas as needed for values over $1,000.arrow_forwardDesign a program that asks the user for a series of names (in no particular order). After the final person’s name has been entered, the program should display the name that is first alphabetically and the name that is last alphabetically. For example, if the user enters the names Kristin, Joel, Adam, Beth, Zeb, and Chris, the program would display Adam and Zeb. This is to be done in Python.arrow_forward
- in python, To terminate the execution of a program the user can a. press Ctrl-C b. press Ctrl-T c. press Ctrl-X d. press Ctrl-Q Help which one !arrow_forwardPYTHON!!!!! Edit the program provided so that it receives a series of numbers from the user and allows the user to press the enter key to indicate that he or she is finished providing inputs. After the user presses the enter key, the program should print: The sum of the numbers The average of the numbers An example of the program input and output is shown below: Enter a number or press Enter to quit: 1 Enter a number or press Enter to quit: 2 Enter a number or press Enter to quit: 3 Enter a number or press Enter to quit: The sum is 6.0 The average is 2.0 # Edit the code below theSum = 0.0 data = input("Enter a number: ") while data != "": number = float(data) theSum += number data = input("Enter the next number: ") print("The sum is", theSum) Results you should get: Input: 1, 2, 3 Output: Enter a number and for exit press Enter: 1 Enter a number and for exit press Enter: 2 Enter a number and for exit press Enter: 3 Enter a number and for exit press Enter:…arrow_forwardTrue or false: You can override the end value in a print statement to change what is added to the end of the output. (python)arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Database System ConceptsComputer ScienceISBN:9780078022159Author:Abraham Silberschatz Professor, Henry F. Korth, S. SudarshanPublisher:McGraw-Hill EducationStarting Out with Python (4th Edition)Computer ScienceISBN:9780134444321Author:Tony GaddisPublisher:PEARSONDigital Fundamentals (11th Edition)Computer ScienceISBN:9780132737968Author:Thomas L. FloydPublisher:PEARSON
- C How to Program (8th Edition)Computer ScienceISBN:9780133976892Author:Paul J. Deitel, Harvey DeitelPublisher:PEARSONDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781337627900Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningProgrammable Logic ControllersComputer ScienceISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education
Structured Chart; Author: Tutorials Point (India) Ltd.;https://www.youtube.com/watch?v=vdUO-sGA1DA;License: Standard YouTube License, CC-BY
Introduction to Structure Charts; Author: Christopher Kalodikis;https://www.youtube.com/watch?v=QN2bjNplGlQ;License: Standard Youtube License