title: simple menu in python 3
body: <p>I have created a two level menu (see code below) and is not working correct. </p>
  
  <p>I noticed that i have to enter the numbers twice to work. and the 2nd level menu does not work</p>
  
  <p>I wonder if you could help. </p>
  
  <p>Thank you</p>
  
  <pre><code>def main():
  
  choice =''
  while choice !='0':
      choice = input ('Main choice: type: \nchoice 1: \nchoice 2: \nchoice 3: \nchoice 4:  \nchoice 5: \nchoice 6: ')
      print ('main menu 0')
      if choice =='1':
          print ('choice 1 - first level')
          choice = input ('Main choice: type: \nchoice 1: \nchoice 2:\nchoice 3 to go back:')
          if choice =='1':
              print ('choice 1:1 - end level menu')
              choice = input ('Main choice: type: \nchoice 1: \nchoice 2:\nchoice 3 to go back:')
          elif choice =='2':
              print ('choice 2:1 - end level menu')
              choice = input ('Main choice: type: \nchoice 1: \nchoice 2:\nchoice 3 to go back:')
          elif choice =='3':
              break
      elif choice =='2':
          print ('choice 2- first level')
          choice = input ('Main choice: type: \nchoice 1: \nchoice 2: \nchoice 3: \nchoice 4:  \nchoice 5: \nchoice 6: ')
  
      elif choice =='3':
          print ('choice 3- first level')
          choice = input ('Main choice: type: \nchoice 1: \nchoice 2: \nchoice 3: \nchoice 4:  \nchoice 5: \nchoice 6: ')
  
      elif choice =='4':
          print ('choice 4 - first level')
          choice = input ('Main choice: type: \nchoice 1: \nchoice 2: \nchoice 3: \nchoice 4:  \nchoice 5: \nchoice 6: ')
  
      elif choice =='5 - first level':
          print ('choice 5')
          joice = input ('Main choice: type: \nchoice 1: \nchoice 2: \nchoice 3: \nchoice 4:  \nchoice 5: \nchoice 6: ')
  </code></pre>
  
  <p>main()</p>