How to develop C programmes without an IDE in Windows?

前端 未结 11 1356
耶瑟儿~
耶瑟儿~ 2021-02-09 18:52

I want to have a deeper understanding of how C programmes are run.

But IDEs stops us from doing that.

So is it possible that I manually set up the environment an

11条回答
  •  时光取名叫无心
    2021-02-09 19:02

    As others have said, install MinGW (I'm assuming you are using Windows) and put its bin directory on your path. Open a command line windows, and create a file with a text editor, such as notepad - call it foo.c:

    #include 
    int main() {
      printf( "hello world\n" );
      return 0;
    }
    

    Then, use the gcc compiler to compile it, creating an executable called foo.exe:

    > gcc foo.c -o foo.exe
    

    lastly, run foo.exe from the command line:

    > foo.exe
    hello world
    

提交回复
热议问题