title: c++ return if invalid input
body: <p>I have done up a program which requires the following:</p>
  
  <ol>
  <li>prompts user input account no </li>
  <li>prompts user input account type
  
  <ol start="2">
  <li>if account <code>type == a</code>, prompts some input and does a certain formula [if]</li>
  <li>if account <code>type == b</code>, prompts some input and does another formula [else if]</li>
  <li>if account type is wrong(not a or b), prompts error and return to 2 [else]</li>
  </ol></li>
  <li>prompts user input to exit [do while]
  
  <ol start="3">
  <li>if <code>input == y</code>, exits</li>
  <li>if <code>input == n</code>, return to 1</li>
  </ol></li>
  </ol>
  
  <p>at the moment I'm pretty stuck at 2.3.
  it prompts the error and goes to 3 instead of returning to 2 to prompt user input.</p>
  
  <p>where is the problem? the else?</p>