Had a quick question. I am writing a small bit of code to help do some math for a game we play. I first have it ask for a number and then ask for a letter. When I tested the first part of this code it hangs in the console and won't move to the next question.
I am t a loss to understand why it won't print the second printf line. It seems so simple? The code is not finished yet but this little part should work even though the code is not completed yet I wold think.
Thanks
-Lars
Code:
#include <stdio.h>
int main (int argc, const char * argv[]) {
int level;
char crit;
printf("Enter the level of the Character:");
scanf( "%d\n", &level );
printf("Enter the Crit letter:");
scanf( "%c", &crit );
return 0;
}
I am t a loss to understand why it won't print the second printf line. It seems so simple? The code is not finished yet but this little part should work even though the code is not completed yet I wold think.
Thanks
-Lars