How to pause in C?

后端 未结 10 899
清歌不尽
清歌不尽 2020-12-05 18:11

I am a beginner of C. I run the C program, but the window closes too fast before I can see anything. How can I pause the window?

10条回答
  •  夕颜
    夕颜 (楼主)
    2020-12-05 18:53

    Good job I remembered about DOS Batch files. Don't need Getchar() at all. Just write the batch file to change directory (cd) to the folder where the program resides. type the name of the exe program and on the next line type pause. example:

    cd\
    

    wallpaper_calculator.exe pause

提交回复
热议问题