Question: PHYTON Upvote for QUICK working code. Please follow the directions. Thank you. Write a program that opens file numbers.txt which contains a series of names

PHYTON Upvote for QUICK working code. Please follow the directions.

PHYTON Upvote for QUICK working code. Please follow the directions. Thank you.

Thank you.

Write a program that opens file numbers.txt which contains a series of names followed by integers. The program read the data from the file and prints total number of integers, the sum of all the numbers, the count of even numbers, and the average of all the numbers. For example, if the input file contains the following text! Dan 3 Cordelia 7 Tanner 14 Mellan 13 Curtis 4 Amy 12 Nick 6 Then the function should produce the following console output: count = 7 sum = 59 evens = 4 average = 8.428571428571429 *numbers - Notepad File Edit Format View Help directions: create a text file and include the data save it as numbers open the file use loop to read the lines in the file counter for number of lines Acc to add all numbvers counter for number of even values and a condition ave. = sum / number of lines

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!