How can i loop the question whenever the user inputs an invalid answer.
for example..
/* question #1 */
cout<< "#1. 5+5=?" <<endl<< "A. 10" <<endl<< "B. 2" <<endl<< "C. 3" << "Your answer is.. ";
cin>>ans;
if(ans=='A')
/* valid.. proceed to question 2 */
else if (ans=='B')
/* valid.. proceed to question 2 */
else if (ans=='C')
/* valid.. proceed to question 2 */
else
cout<<"Invalid answer.. do you wish to go back to the previous question? Y/N";
cin>>ans2;
if (ans2=='N');
exit program.
else
/* This is my problem XD.. how can i make it go back to question number 1? */