title: Leap-year program in Python
body: <p>I'm having a very hard time troubleshooting my code. All I'm trying to do is have the user enter in a starting and an ending year, and then be able to calculate all the leap years in between. I'm still very new to Python, and just can't figure out why my while loop isn't doing what I want it to do. </p>
  
  <pre><code>starting = int(raw_input('Enter starting year: '))
  ending = int(raw_input('Enter ending year: '))
  print 'Leap years between', starting, 'and', ending
  while starting &lt;= ending:
      if starting % 4 == 0 and starting % 100 != 0:
         print starting
      if starting % 100 == 0 and starting % 400 == 0:
         print starting
      starting = starting + 1
  </code></pre>
  
  <p>That is what I have right now. I really would prefer not to have the answer just given to me, but if I could get a little hint as to why my while loop isn't working I would really appreciate it.</p>
  
  <p>This is the output I see in my IDE:</p>
  
  <p><img src="https://i.stack.imgur.com/hrc9n.jpg" alt="screenshot of ide"></p>