Starting Out with Programming Logic and Design (4th Edition)
4th Edition
ISBN: 9780133985078
Author: Tony Gaddis
Publisher: PEARSON
expand_more
expand_more
format_list_bulleted
Textbook Question
Chapter 3, Problem 1AW
Design a module named timesTen. The module should accept an Integer argument. When the module is called, it should display the product of its argument multiplied times 10.
Expert Solution & Answer
Want to see the full answer?
Check out a sample textbook solutionStudents have asked these similar questions
1. Retail Price CalculatorWrite an application that accepts from the user the wholesale cost of an item and its markup percentage. (For example, if an item’s wholesale cost is $5 and its retail price is $10, then the markup is 100%.)The program should contain a function named CalculateRetail that receives the wholesale cost and markup percentage as arguments, and returns the retail price of the item. The application’s form should look something like the one shown in Figure 6-22.
Population Tracker
Learning Objective: Using Python Repetition and Loop Statements
Problem Description
Write a Python program (Console and GUI) that predicts the approximate size of a population of organisms.
The application should use text boxes to allow the user to enter the following information:
starting number of organisms,
the average daily population increase (as a percentage), and
the number of days the organisms will be left to multiply.
For example, assume the user enters the following values:
Starting number of organisms: 2
Average daily increase: 30%
Number of days to multiply: 10
The program should display the following table of data
Mail Delivery Service
Create a Python application, Delivery.py for a delivery service. The program should prompt the user for the
following inputs.
A code representing the delivery area. A local delivery is code 1, and a long distance delivery is code 2.
A weight, in pounds of the item to be delivered.
The program will then display the fee for the item based on the delivery type and its weight. The fee for the
delivery, as follows:
1.
Distance
Fee (S)
Weight
Under 5 pounds
5 to 20 pounds
Over 20 pounds
Under 5 pounds
5 pounds or more
1
12.00
1
16.50
1
22.00
2
35.00
2
47.95
For examples: (These outputs are from different runs. They are not from a loop.)
Delivery Service
Enter Distance (1) Local - (2) Long Distance:
Enter weight: 4.9
------ Summary
Delivery Type: Local
Weight: 4.9 pounds
Fee: $12.00
Delivery Service
Enter Distance (1) Local - (2) Long Distance:
Enter weight: 4.9
--------- Summary
Delivery Type: Long Distance
Weight: 4.9 pounds
Fee: $35.00
Delivery Service
Enter Distance…
Chapter 3 Solutions
Starting Out with Programming Logic and Design (4th Edition)
Ch. 3.1 - What is a module?Ch. 3.1 - Prob. 3.2CPCh. 3.1 - Prob. 3.3CPCh. 3.1 - Prob. 3.4CPCh. 3.1 - Prob. 3.5CPCh. 3.2 - In most languages, a module definition has what...Ch. 3.2 - Prob. 3.7CPCh. 3.2 - Prob. 3.8CPCh. 3.2 - Prob. 3.9CPCh. 3.3 - What is a local variable? How is access to a local...
Ch. 3.3 - What is a variables scope?Ch. 3.3 - Prob. 3.12CPCh. 3.3 - Prob. 3.13CPCh. 3.4 - Prob. 3.14CPCh. 3.4 - What are the variables that receive pieces of data...Ch. 3.4 - Prob. 3.16CPCh. 3.4 - Prob. 3.17CPCh. 3.4 - Prob. 3.18CPCh. 3.5 - What is the scope of a global variable?Ch. 3.5 - Give one good reason that you should not use...Ch. 3.5 - Prob. 3.21CPCh. 3 - A group of statements that exist within a program...Ch. 3 - Prob. 2MCCh. 3 - The first line of a module definition is known as...Ch. 3 - Prob. 4MCCh. 3 - Prob. 5MCCh. 3 - A design technique that programmers use to break...Ch. 3 - Prob. 7MCCh. 3 - A _____ is a variable that is declared inside a...Ch. 3 - A(n) ____ is the part of a program in which a...Ch. 3 - A(n) ____ is a piece of data that is sent into a...Ch. 3 - A(n) ____ is a special variable that receives a...Ch. 3 - When _____, only a copy of the argument's value is...Ch. 3 - When ____, the module can modify the argument in...Ch. 3 - A variable that is visible to every module in the...Ch. 3 - When possible, you should avoid using _____...Ch. 3 - The phrase divide and conquer means that all of...Ch. 3 - Prob. 2TFCh. 3 - Module names should be as short as possible.Ch. 3 - Prob. 4TFCh. 3 - A flowchart shows the hierarchical relationships...Ch. 3 - Prob. 6TFCh. 3 - A statement in one module can access a local...Ch. 3 - In most programming languages, you cannot have two...Ch. 3 - Programming languages typically require that...Ch. 3 - Most languages do not allow you to write modules...Ch. 3 - When an argument is passed by reference, the...Ch. 3 - Prob. 12TFCh. 3 - Prob. 1SACh. 3 - Prob. 2SACh. 3 - Prob. 3SACh. 3 - What is a local variable? What statements are able...Ch. 3 - In most languages, where does a local variables...Ch. 3 - What is the difference between passing an argument...Ch. 3 - Prob. 7SACh. 3 - Design a module named timesTen. The module should...Ch. 3 - Examine the following pseudocode module header,...Ch. 3 - Look at the following pseudocode module header:...Ch. 3 - Assume that a pseudocode program contains the...Ch. 3 - Design a module named getNumber, which uses a...Ch. 3 - What will the following pseudocode program...Ch. 3 - What will the following pseudocode program...Ch. 3 - Find the error in the following pseudocode. Module...Ch. 3 - Find the error in the following pseudocode. Module...Ch. 3 - Find the potential error in the following...Ch. 3 - Prob. 4DECh. 3 - Kilometer Converter Design a modular program that...Ch. 3 - Prob. 2PECh. 3 - How Much Insurance? Many financial experts advise...Ch. 3 - Prob. 4PECh. 3 - Prob. 5PECh. 3 - Prob. 6PECh. 3 - Calories from Fat and Carbohydrates A nutritionist...Ch. 3 - Prob. 8PECh. 3 - Prob. 9PECh. 3 - Monthly Sales Tax A retail company must file a...Ch. 3 - Prob. 11PE
Additional Engineering Textbook Solutions
Find more solutions based on key concepts
A method in a subclass that has the same signature as a method in the superclass is an example of __________. a...
Starting Out with Java: From Control Structures through Objects (6th Edition)
To open a file for reading, you use the following classes. a. File and Writer b. File and Output c. File and In...
Starting Out with Java: Early Objects (6th Edition)
Explain the problems that denormalized tables may have for insert, update, and delete actions.
Database Concepts (8th Edition)
Celsius and Fahrenheit Temperature Converter Assuming that C is a Celsius temperature, the following formula co...
Starting out with Visual C# (4th Edition)
The following code transposes the elements of an M M array, where M is a constant defined by #define. When com...
Computer Systems: A Programmer's Perspective (3rd Edition)
What output will be produced by the following code?
Java: An Introduction to Problem Solving and Programming (8th 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
- C# Account numbers sometimes contain a check digit that is the result of a mathematical calculation. The inclusion of the digit in an account number helps ascertain whether the number is a valid one. Write an application named CheckDigit that asks a user to enter a four-digit account number and determines whether it is a valid number. The number is valid if the fourth digit is the remainder when the number represented by the first three digits of the four-digit number is divided by 7. For example, 7770 is valid, because 0 is the remainder when 777 is divided by 7. If the account number is valid, output The account number is valid. If the account number is invalid output Invalid. If the account number is too short or too long output Account number invalid - it must have 4 digits.arrow_forwardValidy options is: Valid / Invalidarrow_forwardUs------c. Prak 9 Instructions PDF -mming Prak 9 Chapter 6: Modularizing Your Code with Methods 1. Salesperson's Commission Calculator (Nr 1, Page 408) Create an application that lets the user enter a salesperson's revenue sale and the rate of commission paid by the company, and display the commission earned. For example: • If a salesperson sells $100,000 in revenue while working with a company that pays 5 percent of the revenue, his/her commission check will be $5,000. • if a salesperson sells $100,000 in revenue while working with a company that pays 8 percent of the revenuo, his/her commission check will be $8,000. The program should have a method named CalculateDisplayCommission that receives the revenue sale by a salesperson and the commission percentage as arguments, and calculates and displays the commission earned by the salesman. See examples below: Salesperson's Commis. |Salesperson's Commis. 100000 Revenue Sale: 100000 Revenue Sale: Commission Percentage: Commission…arrow_forward
- 99 question Reza Enterprises sells tickets for buses, tours, and other travel services. Because Reza frequently mistypes long ticket numbers, Reza Enterprises has asked his students to write an application that shows if a ticket is invalid. Your application/program tells the ticket agent to enter a six-digit ticket number. Ticket numbers are designed so that if you lose the last digit of the number, then divide by 7, the remainder of the division is exactly the same to the last dropped digit. This process is shown below: Step 1: Enter the ticket number; for example 123454 Step 2: Remove the last digit, leaving 12345 Step 3: Determine the remainder when the ticket number from step 2 is divided by 7. In this case, 12345 divided by 7 leaves a remainder of 4. Step 4: Display a message to the ticket agent indicating whether the ticket number is valid or not. If the ticket number is valid, save the number to a .txt file called “tickets.txt” and.arrow_forwardThe value passed through the parameter is called a(n). Index argument statement numberarrow_forwardWrite the pseudocode for an application that will request three numbers from a user. The application should then determine and display the largest of the three numbers.arrow_forward
- Intro to Python Programmingarrow_forwardlanguage JAVAarrow_forwardPlease provide answer in C#: Slot Machine Simulation A slot machine is a gambling device into which the user inserts money and then pulls a lever (or presses a button). The slot machine then displays a set of random images. If two or more of the images match, the user wins an amount of money that the slot machine dispenses back to the user. Create an application that simulates a slot machine. Figure 8-23 (on page 539 of your book) shows an example of how the form should look. The application should let the user enter into a TextBox the amount of money he or she is inserting into the machine. When the user clicks the Spin button, the application should display three randomly selected symbols. (Slot machines traditionally display fruit symbols. You will find a set of fruit symbols attached to this dropbox for your use - from the Student Sample Programs provided by the book author.) If none of the randomly displayed images match, the program should inform the user that he or she has won…arrow_forward
- *program must be made in C# using visual studio* You will be creating a program that will allow the user to enter information about a home rental. The program should allow them to enter the name of the rental, the number of months the rental will be used, the cost per a single month and the total budget allowed to rent. There should be a button that will then calculate the total cost of the rental, as well as output the name, number of months, individual cost and total cost of the rental each in their own label. In addition, there should be a label that lets the user know if the rental would be over or under the budget entered. The number of months will need to be entered as a number between 0 and 13. If they enter a number outside of that range, when the calculation button is clicked a label should show up letting the user know the number of months entered was not in the correct range. A similar check should be performed for the individual cost and budget, one that ensures a number…arrow_forwardC CODE: create a program that will test the user’s proficiency in solving different types of math problems. The program will be menu-driven. The user will select either addition, subtraction, multiplication, or division problems. The program will then display a problem, prompt the user for an answer, and then check the answer displaying an appropriate message to the user whether their answer was correct or incorrect. The user will be allowed 3 tries at each problem. The program will also keep statistics on how many problems were answered correctly. add functions to allow the user to select problems of varying degrees of difficulty In the next Week, you'll need to add functionality to also keep statistics on the number of correct answers vs. the total number of problems attempted. So now let’s add the code for the remaining functions: We’ll start by inserting code to ask the user if they want to see problems that are easy, medium, or difficult. We’ll do this by prompting them to…arrow_forwardProgram Unit Score Calculator Console App Write a Python Console Application program that allows the user to enter the marks for different assessments in a unit, and computes the total mark and grade for the unit. Here is the program logic specification: There are six assessment activities Quiz1, Quiz2, Quiz3, Quiz4, Lab Journal, Major Assignment and Final Exam. The four quizzes are worth 5 marks each, the Lab Journal is worth 10 marks, the Major Assignment is worth 30 marks and the Final Exam is worth 40 marks. The algorithm for computing the total mark for the unit is: Total Mark = Quiz1+Quiz2+Quiz3+Quiz4+Major Assignment+ Lab Journal + Final Exam The following screenshot shows a successful test run:arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Programming Logic & Design ComprehensiveComputer ScienceISBN:9781337669405Author:FARRELLPublisher:CengageC++ for Engineers and ScientistsComputer ScienceISBN:9781133187844Author:Bronson, Gary J.Publisher:Course Technology PtrMicrosoft Visual C#Computer ScienceISBN:9781337102100Author:Joyce, Farrell.Publisher:Cengage Learning,
- Programming with Microsoft Visual Basic 2017Computer ScienceISBN:9781337102124Author:Diane ZakPublisher:Cengage LearningEBK JAVA PROGRAMMINGComputer ScienceISBN:9781305480537Author:FARRELLPublisher:CENGAGE LEARNING - CONSIGNMENTEBK JAVA PROGRAMMINGComputer ScienceISBN:9781337671385Author:FARRELLPublisher:CENGAGE LEARNING - CONSIGNMENT
Programming Logic & Design Comprehensive
Computer Science
ISBN:9781337669405
Author:FARRELL
Publisher:Cengage
C++ for Engineers and Scientists
Computer Science
ISBN:9781133187844
Author:Bronson, Gary J.
Publisher:Course Technology Ptr
Microsoft Visual C#
Computer Science
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Cengage Learning,
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:9781337102124
Author:Diane Zak
Publisher:Cengage Learning
EBK JAVA PROGRAMMING
Computer Science
ISBN:9781305480537
Author:FARRELL
Publisher:CENGAGE LEARNING - CONSIGNMENT
EBK JAVA PROGRAMMING
Computer Science
ISBN:9781337671385
Author:FARRELL
Publisher:CENGAGE LEARNING - CONSIGNMENT
Graphical User Interfaces: Crash Course Computer Science #26; Author: CrashCourse;https://www.youtube.com/watch?v=XIGSJshYb90;License: Standard YouTube License, CC-BY
Python GUI | How To Make A GUI In Python | Best GUI Framework In Python | Edureka; Author: edureka!;https://www.youtube.com/watch?v=_PHJvjQJa3w;License: Standard Youtube License