I can't see what's wrong here, any idea why when I enter q ( which should jump out of the loop ) does the program begin an infinite loop:
Code:do { title (); // a self-defined function for printing text printf("\nPlease enter the cost of the item(s)\n"); printf("(Press q to finish)\n:"); scanf("%f",&price); clrscr(); cost += price; } while ( price != 'q' );