subject
Computers and Technology, 05.10.2019 01:20 med69

#read_running_times. py # chapter 6.2 page 258 def main(): # open the video_times. txt file for reading. video_file = open('video_times. txt', 'r') # initialize an accumulator to 0.0 total = 0.0 # initialize a variable to keep count of the videos. count = 0 print('here are the running times for each video: ') # get the values from the file and total them. for line in video_file # convert a line to a float. run_time = float(line) # add 1 to the count variable. count += 1 # display the time. print('video #', count, ': ', run_time, sep='') # add the time to total. total += count # close the file video_file. close() # display the total of the running times. print('the total running time is', total, 'seconds.') # call the main function main()

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 17:00
Which of the following is not contained on the slide show toolbar? a. next button b. slide button c. close button d. pen too
Answers: 2
question
Computers and Technology, 23.06.2019 02:30
People with high self-esteem: accept their strengths and weaknesses. believe that failed experiences are failures of their whole self. feel good about who they are only when they reach total success. need positive external experiences to counteract negative feelings that constantly plague them.
Answers: 1
question
Computers and Technology, 23.06.2019 12:00
If you're using an existing powerpoint presentation that will receive new slides based on a word outline, select the a. slide that will appear after the new slides. b. first slide in the presentation. c. slide that will appear before the new slides. d. last slide in the presentation.
Answers: 2
question
Computers and Technology, 23.06.2019 15:20
What does a bonus object do? a. subtracts lives b. keeps track of a player's health c. gives a player an advantage d. makes text appear
Answers: 1
You know the right answer?
#read_running_times. py # chapter 6.2 page 258 def main(): # open the video_times. txt file for rea...
Questions
question
Mathematics, 07.04.2021 01:00
question
English, 07.04.2021 01:00
question
Physics, 07.04.2021 01:00
Questions on the website: 13722361