NA BRGVI – Python programming week 3
Description
Unformatted Attachment Preview
ne Word document (the file name must be Lab3B.docx) containing:
o Screenshots: the testing and outputs of the execution of your Python programs.
o Copies of your Python programs: no images/screenshots of your code! The
copies must be in %xt&ormat.
o Important:
? your testing screenshots must include the sample testing cases shown
below and another testing case of yours.
? Items in this Word document must be in the same order as the questions.
Your Python programs (that is, the .py program files)¯te that there are specific
requirements on the program names:
o Your code must be properly commented (like the examples in Code Archive; you
don have to comment on every line of code.)
o On the top of your program, there must be 3~5 lines of the comments with your
full name and date/time when you have completed the programs.
(Attach/submit/upload the Word file and your program files individually; do not zip the
programs.)
Q1 (40 points) Write a program !b3B01.py4hat prompts the user to enter a number in the
range 1 to 999.99 (inclusive) and validates the input by using while-loop. Loop until user
enters: 555.55. Print the inputted number with 2 decimal placesåe the following example.
The screenshot of your program execution would look like the following:
1
Q2 (40 points) Write a program !b3B02.py(at creates a list of 5 integers (prompting for
inputs and add to the list one by one), print the list. Then convert the list to a tuple (simply with
use of the function tuple(..) ) and print the tuple in reversed order. You need to use while-loop.
Use the following example for your implementation.
The screenshots of your program executions would look like the following:
2
Q3 (60 points) Write a program !b3B03.py4hat lets the user enter the total sales in dollars
for each of a week into a list (use a loop for this task). The program should then calculate and
display the total sales for the week, the average sales, and which days with the highest and
lowest sales. Use a tuple or list to hold weekday names. Use a list to hold the sales per each
week. The calculated sales output should be floating number with 2 decimal places. Use the
following sample to guide your implementation. Also use while-loop to check the week sales
input and for-loop to calculate the total.
The screenshot of your program execution would look like the following:
3
Purchase answer to see full
attachment
Have a similar assignment? "Place an order for your assignment and have exceptional work written by our team of experts, guaranteeing you A results."