printf("Please type Y if you want us to compute the monthly Rate for new data and N otherwise: ");
scanf("%c",&ans);
while ((ans!='y') && (ans!='Y') && (ans!='n') && (ans!='N')){
printf("Please type Y if you want us to compute the monthly Rate for new data and N otherwise: ");
scanf("%c",&ans);}
if (ans == 'N' || ans == 'n'){
printf("Thank you Please visit us again");}
else if (ans == 'Y' || ans == 'y')
While executing this if i enter an n or y it works the right way but if i enter something that isnt an n or y the output lets me input another value but instead of it saying Please type Y if you want us to compute the monthly Rate for new data and N otherwise: it says that twice and i cannot figure out why it would say it twice.