title: Check if user input is an integer
body: <p>My current code:</p>
  
  <pre><code>mylist = [0] * 7     
  for x in range(7):
          sales=-1
          while (sales&lt;0):
              sales = float(input("Sales for day {0}:".format(x)))
              mylist[x] = sales
  
              if  sales &lt; 0:
                  print ("Sorry,invalid. Try again.")
  
  
   print (mylist)
  
  best = max(mylist)
  worst = min(mylist)
  average = sum(mylist)/len(mylist)
  total = sum(mylist)
  
  print ("Your best day had", best, "in sales.")
  print ("Your worst day had", worst, "in sales.")
  print ("Your average daily sales were:", format(average,'.2f'))
  print ("Your total sales were:", format(total, '.2f'))
  </code></pre>
  
  <p>When I run it I get this: the first one works, my question is about the second time i run it</p>
  
  <pre><code>Sales for day 0: 5
  Sales for day 1:4
  Sales for day 2:6
  Sales for day 3:7
  Sales for day 4:8
  Sales for day 5:2
  Sales for day 6:3
  [5.0, 4.0, 6.0, 7.0, 8.0, 2.0, 3.0]
  Your best day had 8.0 in sales.
  Your worst day had 2.0 in sales.
  Your average daily sales were: 5.00
  Your total sales were: 35.00
  
  
  
  Sales for day 0: 5
  Sales for day 1:4
  Sales for day 2:3
  Sales for day 3:-4
  Sorry,invalid. Try again.
  Sales for day 3:four
  Traceback (most recent call last):
  line 44, in &lt;module&gt;
  sales = float(input("Sales for day {0}:".format(x)))
  ValueError: could not convert string to float: 'four'
  </code></pre>
  
  <p>How do I recode this so that python will also re-prompt the user to enter in another integer if they decide to say something like "four" instead of a number thanks alot.</p>