title: A problem in python odd or even function. Returning True is not working
body: <pre><code>def is_even(x) :
        while x:
             if x==0:
                 return True
             elif x==1:
                 return False
             x-=2
  print(is_even(5)) 
  print(is_even(6))
  </code></pre>
  
  <p><strong>output</strong>
  <em>False</em>
  <em>None</em></p>
  
  <p>If the <code>x==0</code> is replace with <code>x==2</code> it works fine. Please explain why returning True is not working for <code>x==0</code>. </p>