title: Python max value from a text file
body: <p>I'm trying to calculate max/min from a text file containing numbers, but can't figure out how. I was able to do count and total, but not max/min. Any help would be much appreciated. Thanks!</p>
  
  <pre><code>def main():
      counter = 0
      total = 0
      inputFile = open('Numbers.txt', 'r')
  
      for numbers in inputFile:
          numbers = float(numbers.rstrip())
  
          total += numbers
          counter += 1   
  
      print('Count:', counter)
      print('Total:', total)
      print('Average:', total / counter)
  
      inputFile.close()
  
  main()
  </code></pre>