[ad_1]
Try removing ‘\n’ from the scanf, like this:
scanf ("%i",&x);
Take a look at this discussion for additional info on using ‘\n’ in a scanf:
Using ā\nā in scanf() in C
2
[ad_2]
solved C-Program – Taking extra entry to end program
[ad_1]
Try removing ‘\n’ from the scanf, like this:
scanf ("%i",&x);
Take a look at this discussion for additional info on using ‘\n’ in a scanf:
Using ā\nā in scanf() in C
2
[ad_2]
solved C-Program – Taking extra entry to end program