Dev-C++基本使用
DEV C++ 使用总结
1、DEV C++ 不能调试 (1)tools->compiler option->settings->linker里设置为yes后,Generate debugging information,并且Rebuild All 了。 (2)在“工具”-》编译选项-》"Add following commands when calling complier编译时加入下面命令"的编辑框里加上:-g3,在下面的"Add these commands to the linker command line在连接器命令行加入以下命令" 下的编辑框上加上:-g3 (3)转到programs程序页,把gcc行修改为:gcc.exe -D__DEBUG__,把g++行修改为g++.exe -D__DEBUG__ ,点击ok。 (4)重新编译,就能调试了。 2、使用Dev—c++时,如何结决控制台程序运行时的控制台窗口只闪一下就自己关了的问题,解决方案有以下几种 (1)引入#include <conio.h>,并在返回之前使用getch()。对于freopen()也使用。注:此处使用getchar()也不好使。s (2)引入#include ,返回之前添加system("PAUSE");但对于freopen()不适用