LAB ASSIGNMENT IMPORTANT: you need to complete the PDP thinking process for each program. Turn in item 1): one complete PDP 2) random_num list.py make a copy of the mipo_ex.py file from Chapter 3*. Rename and use it to create the new program. docx, on the program of your choice. Welcome to our random number game. How many integers should the computer pick for your list? Please enter a whole number: five You can only enter a number 1 or higher: 5 In inputs() set up an empty list, and ask the user how many numbers he/she wants the program to pick for the list. Set up a loop that runs the user-defined number of times. In the loop, the program will pick a random integer, and add each one to the list. Finish by sorting and returning the list. randomly selected & sorted: (0, 2, 3, 4, 91 Here is your list - printed w/shortcut method: 0, 2, 3, 4, 9 Tea0a yaTA 'door UTA paauTzd Your list minimum was 0 and maximum was 9. this time. 8T = 6 + +E + 2 +0 Would you like to pick again? Entery or n: In processing(), take in the number list as a parameter, and use Python list functions to find & return the total, minimum and maximum of the number list. In outputs(), take in all of the variables that the program has produced, as parameters. Then print 4 ways, showing options to display list info (see slide 13-15 & output sample) The user decides how many numbers will be picked for the list. HINT: PPT ch. 3 has code to pick random numbers. *Features in place > Functions: main, inputs, processing, outputs & get pos_int, with exception handling & restart in main(). Also includes comments - ""docstring"" at top and # short throughout. 2

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

Python 

**Lab Assignment**

**Important:** You need to complete the PDP thinking process for each program. Turn in a `.docx` on the program of your choice.

1. **Random.py:**
   - Make a copy of the file and use it to create the new program. Rename the new program.

2. **Inputs:**
   - Set up an empty list—ask the user how many numbers they want to pick for their list. 
   - Use a loop that many times to populate the list with random integers. 
   - Manage the user-defined number of items in the list. 
   - Finish by sorting the list.

3. **In Processing:**
   - Take in the number list as a parameter and use Python functions to find and return the minimum, maximum, and mean of the numbers.

4. **Outputs:**
   - The main program takes in all the parameters and prints the list, minimum, maximum, and mean values. 
   - The expected output would display a list of values (e.g., 3, 15, 8, 30, 50).

The use of Python code includes comments, describing steps at the top and throughout.

**Explanation of Graphic:**

There is a screenshot of a Python code that demonstrates generating and processing a list of random numbers. 

- The user decides how many numbers will be picked for the list, and the program, `random.py`, has a code to pick these random numbers.
- The list is sorted and displayed along with its minimum, maximum and mean values once processed.
Transcribed Image Text:**Lab Assignment** **Important:** You need to complete the PDP thinking process for each program. Turn in a `.docx` on the program of your choice. 1. **Random.py:** - Make a copy of the file and use it to create the new program. Rename the new program. 2. **Inputs:** - Set up an empty list—ask the user how many numbers they want to pick for their list. - Use a loop that many times to populate the list with random integers. - Manage the user-defined number of items in the list. - Finish by sorting the list. 3. **In Processing:** - Take in the number list as a parameter and use Python functions to find and return the minimum, maximum, and mean of the numbers. 4. **Outputs:** - The main program takes in all the parameters and prints the list, minimum, maximum, and mean values. - The expected output would display a list of values (e.g., 3, 15, 8, 30, 50). The use of Python code includes comments, describing steps at the top and throughout. **Explanation of Graphic:** There is a screenshot of a Python code that demonstrates generating and processing a list of random numbers. - The user decides how many numbers will be picked for the list, and the program, `random.py`, has a code to pick these random numbers. - The list is sorted and displayed along with its minimum, maximum and mean values once processed.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY