PART A – CHOOSE YOUR SALARY
Salary Options: You are offered two salary options for a fixed number of days. Option A: $300 per day. Option B: $1 the first day, $2 the second day, $4 the third day, and so on, with the amount doubling each day. Determine which option pays better.
• More specifically, write two functions, optionA and optionB, that will calculate and return the amount of money based on a single integer argument, the number of days worked.
• Your program should ask the user to enter from the keyboard the number of days worked.
• It should call each function and store those results to wages1 and wages2. Both of those should be printed to the screen.
• Finally, your program should print out which option is better.
• Here is an example of the screen interaction if the user were to type in 10 for the number of days:
How many days did you work? 10
Option A pays $3000
Option B pays $1023
Option A is better
NOTE: This program must use two functions as described above.
NOTE #2: Function optionB must use a loop.
NOTE #3: Be sure that you use meaningful variables in your code and include appropriate documentation for both the overall program and each function.
• Upload your program to Canvas
PART B – MORE WITH UNA’S PRINT SHOPPE
Remember in Module #3, you wrote a program to compute the cost of a copier:
Copy Cost: Una’s Print Shoppe charges 12 cents per copy for the first 100 copies and 7 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 project, you will modify your earlier program 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.
• Upload both files.
Grading Rubric
F-D C B A
No documentation is included. Major parts of documentation are missing. Minor part of documentation is missing. Adequate documentation is included.
Program has major functionality issues. Program has multiple minor functionality issues. Program has 1-2 minor functionality issues. Program functionality is correct.
Programming style does not meet specified requirements. Programming style is lacking in multiple areas. Programming style is mostly adhered to. Programming style is adhered to.
Output is formatted incorrectly. Output contains multiple minor errors. Output is mostly formatted correctly. Output is formatted correctly.
Program has syntax errors. Program contains zero syntax errors.