title: Voting If/Else/Elif
body: <p>New to Python (and to StackOverflow). Trying to figure out how to get this to execute properly. While the program itself executes fine, I'd like it to not have the extra step in there. What I mean by that is that if it fails the first statement, I'd like to to terminate and print the message associated with the else statement. </p>
  
  <pre><code>def main():
  
      # init
      messageOne = 'You are too young to vote.'
      messageTwo = 'You can vote.'
      messageThree = 'You need to register before you can vote.'
  
      # input
      age = int(input('Please enter your age: '))
      registration = input('Are you registered to vote(Y/N)?: ')
  
      # calculate / display
      if age &gt;= 18:
          if registration.upper() == "Y":
              print(messageTwo)
          else:
              print(messageThree)
      else:
          print(messageOne)
  
  main()
  </code></pre>