Write a function maxTemp which takes a filename as string argument and returns the maximum temperature as float type for the week. Input file will contain temperature readings for each day of the week. Your function should read each line from the given filename, parse and process the data, and return the required information. Your function should return the highest temperature for the whole week. Empty lines do not count as entries, and should be ignored. If the input file cannot be opened, return - 1. Remember temperature readings can be decimal and negative numbers.
+2
Answers (1)
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “Write a function maxTemp which takes a filename as string argument and returns the maximum temperature as float type for the week. Input ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Home » Computers & Technology » Write a function maxTemp which takes a filename as string argument and returns the maximum temperature as float type for the week. Input file will contain temperature readings for each day of the week.