Question: Problem Description and Given Info You must alter the program that you are given below in Python. The program you are given will open the
Problem Description and Given Info
You must alter the program that you are given below in Python.
The program you are given will open the file named "jabberwocky.txt and display the contents of that file to the console.
You must change the code, so that the program will open the file named "crocodile.txt and display the contents of that file to the console.
make no other changes to the code, and make no changes to any of the provided txt files.
Be sure that you carefully read the given code and understand how it works.
lab activity
: Read File Individual Challenge
main.py
Load default template...
myfile openjabberwockytxt # open the file
for line in myfile: # iterate through the lines in the file
line line.rstrip # remove the newline from the end of each line
printline # outut the line
myfile.close # close the file
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
