I just started writing this program... There will be more code inside main, but it already doesn't work as I expected it to...
What it does is: it runs correctly once, and then after execution it runs again, but without stopping for user input? Did I do something wrong???
Thanks...Code:int main() { char again = 'y'; char inputstring[512] = "One, two, three."; char *inputptr; inputptr = inputstring; do { { printf("Enter an English text. Use no more than 511 characters, including white spaces.\n"); gets(inputstring); printf("The text you entered was: "); printf(inputstring); } printf("\nWould you like to enter another text?"); again = getchar(); } while (again == 'y' || again =='Y'); }



LinkBack URL
About LinkBacks


