Following Program Opens Testtxt Displays Contents Nothing Placed Blank Contents File Displ Q37059308

The following program opens test.txt and displays its contents. If nothing is placed in the blank, then the contents of the f

The following program opens test.txt and displays its contents. If nothing is placed in the blank, then the contents of the file is displayed double spaced. What should be placed on the blank so that the contents of the file is displayed without the extra blank lines? infile = open( “test.txt.. , “r”) line = infile. readline() while line !-“”: print(line) line = infile.readline() infile.close() Select one: o a. line line.1strip() b. infile-infile.lstrip() c. infile-infile.rstrip()

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.