ok not sure how to accomplish my goal but's it's simple i want the program to ask if 125 was the correct amount entered but im not sure what is the simplest way to accomplish that i cant seem to get while and if to work. the program hangs on the if i know where the chack should go in the codde but i cant figre it out any suggestions would be helpful
/code
#include <stdio.h>
int main (void)
{
float Tax[3]={7.25, 7.5, 7.75}; //this float is the number that are used for the tax wiht the differnt places
float A = 0.0f; // this is the price of the item that will be used to find tax
int B = 0; // this is will pick the data that will be muiltply the tax
char ANS = ' ' ;
printf("Enter price of item: "); // this will be disply on the screen
scanf("%f", &A ); // this is where the price will be assigned to the a value
printf( "You enter %.2f, correct?\n" ,A) ;
scanf ("%s", ANS);
printf("Stores: (1) Delmar, (2) Encintas, (3) La Jolla? "); // this denots what tax percentage will be used
while ((B < 1) || (B > 3))
{ //this is to set the number and display the enter number
scanf("%i", &B ); //u
if ((B < 1) || (B > 3))
printf (" Enter the number associated to the store: "); //this message will appear until a number will be pressed
} // while
printf("The sales tax is %.2f" , A*(Tax[B-1]/100)); //
return 0; //
} // main