you may use getch() instead of getchar(), getch() is included in conio.h
karthigayan, if you dont mind, i will use your code in this example.
you should use a WHILE loop in here, here is an example:
if this seems confusing, the != sign means if 'not equal'. so if OP is
printf("Please Enter the option ( 1 / 2 / 3 ) : ");
while(op != 1 && op != 2 && op != 3)
printf( "You have entered one \n" );
printf( "You have entered two \n" );
printf( "You have entered three \n" );
printf( "Try again\n" );
not 1 nor 2 or 3, then that means the user typed an incorrect number
so the loop keeps going. however, if OP is equal to either 1, 2, or 3
then the loop exits. simple, eh?