Сору Cost:

C++ for Engineers and Scientists
4th Edition
ISBN:9781133187844
Author:Bronson, Gary J.
Publisher:Bronson, Gary J.
Chapter6: Modularity Using Functions
Section6.2: Returning A Single Value
Problem 13E
icon
Related questions
Question
First picture is what I need help with. Second picture is the assignment 6 the first picture references
Copy Cost: Leo's Print Shoppe charges 5 cents per copy for the
first 100 copies and 3 cents per copy for each additional copy. Write
a program that asks for the customer's name and how many copies
they need. Your program should output the customer's name and
the total cost (using a dollar sign and 2 decimal places).
For this assignment, you will modify assignment #6 so that it uses
functions:
* Write a copyCost function that will have one argument, the
number of copies. It should compute the cost based on the given
formula and then return that cost.
* Write a main function that will ask for the customer's name and
the number of copies. It will then make a call to your copyCost
function and store the result to a variable. Finally, it should print the
customer's name and the copy cost (using a dollar sign and 2
decimal places).
1) Write a flowchart to model the solution to the problem. Save it as
a PDF document.
2) Implement the solution to your problem as a Python program.
Add a couple of comment lines above each function definition. Add
at least 4 lines of comments at the top.
Transcribed Image Text:Copy Cost: Leo's Print Shoppe charges 5 cents per copy for the first 100 copies and 3 cents per copy for each additional copy. Write a program that asks for the customer's name and how many copies they need. Your program should output the customer's name and the total cost (using a dollar sign and 2 decimal places). For this assignment, you will modify assignment #6 so that it uses functions: * Write a copyCost function that will have one argument, the number of copies. It should compute the cost based on the given formula and then return that cost. * Write a main function that will ask for the customer's name and the number of copies. It will then make a call to your copyCost function and store the result to a variable. Finally, it should print the customer's name and the copy cost (using a dollar sign and 2 decimal places). 1) Write a flowchart to model the solution to the problem. Save it as a PDF document. 2) Implement the solution to your problem as a Python program. Add a couple of comment lines above each function definition. Add at least 4 lines of comments at the top.
Copy Cost: Leo's Print Shoppe charges 5 cents per copy for the
first 100 copies and 3 cents per copy for each additional copy. Write
a program that asks for the customer's name and how many copies
they need. Your program should output the customer's name and
the total cost (using a dollar sign and 2 decimal places).
1) Write an algorithm (pseudocode) to solve the problem. Save it as
a Word document.
2) Write a flowchart to model the solution to the problem. Save it as
a PDF document.
3) Implement the solution to your problem as a Python program.
Add at least 4 lines of comments at the top.
Transcribed Image Text:Copy Cost: Leo's Print Shoppe charges 5 cents per copy for the first 100 copies and 3 cents per copy for each additional copy. Write a program that asks for the customer's name and how many copies they need. Your program should output the customer's name and the total cost (using a dollar sign and 2 decimal places). 1) Write an algorithm (pseudocode) to solve the problem. Save it as a Word document. 2) Write a flowchart to model the solution to the problem. Save it as a PDF document. 3) Implement the solution to your problem as a Python program. Add at least 4 lines of comments at the top.
Expert Solution
steps

Step by step

Solved in 3 steps with 4 images

Blurred answer
Knowledge Booster
Rendering
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
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning