What should I use to get started with C on Windows?

November 16, 2026 4 answers
Asked by 3e!tarmacrane_572

My book uses Code::Blocks, but when I try to build an example, nothing seems to happen. Running it says it hasn't been built. I also tried Visual Studio and found it confusing. What should I try?

Answers

w.629!claspfolder

I'd start by checking the Code::Blocks installation rather than switching tools again. Code::Blocks is an IDE, not the compiler itself. On Windows, look for a Code::Blocks package that includes MinGW, which provides the GCC compiler.

Check the compiler settings in Code::Blocks and make sure it can find GCC. Then build the example and look at the build log for any messages. If it still doesn't work, share the log and the steps you took. That will give people something concrete to troubleshoot.

_q17!sundialrivet.5:

Also check that the example is part of a project and that the project is open when you build it. An open source file alone may not be enough.

Reply to this answer
_g18~foldcompass.4

If you don't mind using a terminal, a basic editor plus GCC is another option. You can compile a file with gcc hello.c -o hello.exe, then run hello.exe from the terminal.

You'll need to install GCC first and make sure the terminal can find it. Typing gcc --version is a quick check. This avoids learning an IDE at the same time as C, though it does mean getting comfortable with terminal commands.

_g62!pocketmeteor.8:

In Windows PowerShell, you can run the resulting program with .\hello.exe from the folder where it was built.

Reply to this answer
_e62!wickerhinge.3

VS Code is another editor worth considering, especially if Visual Studio feels like too much. The C/C++ extension can help with editing, but you still need a compiler and a way to configure the build. It isn't an automatic fix for a missing compiler.

Reply to this answer
n.526~trammarker

Since the book uses Code::Blocks, sticking with it for now could make the examples easier to follow. Try a tiny program first and pay attention to any build messages. Once that works, you can decide whether you like the environment enough to keep using it.

Reply to this answer

Add your answer

Answers are reviewed before publication.

Related Discussions