r/C_Programming • • Sep 18 '26

a big problem

hey guys i m currently learning c language and i m facing an irritating problem like whenever i use scanf in my code to enter any value and when i run the code after saving it so it doesn't run anything it just show that it is running but i m unable to enter the value and the code doesn't run on terminal it runs in the output

so please anyone who can solve this issue can help me?

0 Upvotes

5 comments sorted by

7

u/Snarwin Sep 18 '26

Here's a page that explains several common scanf mistakes and how to fix them:

https://www.sekrit.de/webdocs/c/beginners-guide-away-from-scanf.html

Without seeing your code, it's hard to say exactly what's wrong, but one of the solutions on that page will probably work.

2

u/musbur Sep 19 '26

Don't use scanf. Read the string using fgets and then sscanf.

1

u/flyingron Sep 18 '26

Are you saying that your program is not running in some place you can type into? Like it's running in the output window of Visual Studio or VSCode? You need to tell us a bit more detail.

-5

u/[deleted] Sep 18 '26

[removed] — view removed comment

1

u/C_Programming-ModTeam Sep 18 '26

Your comment does not add value and has been removed.