Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Python Programming LAB # 5 - 4 0 Points Instructions: Assume you have two files containing a series of integers named numbers.txt and numbers 1
Python Programming
LAB # Points
Instructions:
Assume you have two files containing a series of integers named numbers.txt and numbersbxt Wile a progrem that calculates the average of all the numbers stored in the files and handles exceptions.
Steps:
Write code to process each fille:
Calculate the averege
Test for the following errors:
any IOEnor exceptions that are ralsed when the file is opened and data is read from ii
any ValueETror exceptions that are reised when the iltems that are read from the fille are
Include Header below:
# Class: CIST Python Programming I
# Term: Fall
# instructor: Chris Bishop
# Description: Solution to Lab #
#Author: Student Name Here
#
# By turning in this code, I Pledge:
# That I have completed the programming assignment independently.
# I have not copied the code from a student or any source.
# I have not given my code to any student.
Execute the program and take swreen capture of output.
Submit swreen capture and pythonpy filercode via blecthoard.
Sample Resulit:
nutberb e
Average:
nuatiersi file
Monnumerle data found In the tile
Process finished with exit code
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started