Code Editors and IDEs
You have a compiler. Now you need somewhere comfortable to write Rocket Run. The choices seem endless and people argue about them loudly, but they all fit into two groups, and every one of them relies on the compiler you just installed.
The rule
An editor writes code; an IDE also builds, runs and debugs it.
An editor is a tool for writing and changing text, with helpers like syntax colours. An IDE (integrated development environment) bundles editing with building, running and a debugger, usually set up for you.
Common choices:
| Tool | Type | Notes |
|---|---|---|
| Visual Studio | IDE | Windows; ships with the MSVC compiler |
| CLion | IDE | Every platform; organises projects with CMake |
| Xcode | IDE | macOS; uses Apple Clang |
| Qt Creator | IDE | Every platform; free |
| VS Code | Editor | Add the C/C++ or clangd extension |
| Vim, Neovim, Emacs | Editor | Add clangd for smart features |
What turns a plain editor into a smart one is a language server. For C++ the popular one is clangd. It reads your code the way a compiler would and feeds the editor completions, go-to-definition and red squiggles for errors while you type.
Underneath all of them sits a compiler. Pressing the green Run button in any tool simply runs a command like this for you:
g++ -std=c++20 -g rocket.cpp -o rocket && ./rocketThe shortcut
List the three pieces you need and check which one your tool is missing: editor, compiler, debugger.
Editor
VS Code is installed. That covers writing text, and nothing more.
The trap is blaming the editor for a missing compiler. If Run fails with "g++ not found", no editor setting will fix it; install the compiler.
Drills
Answer fast — trust the rule.
You installed only VS Code, and pressing Run says g++ not found. Why?
What does clangd give an editor?
Which of these is an IDE that installs its own C++ compiler on Windows?
One teammate uses CLion, another uses Neovim. Can they work on the same Rocket Run code?
Remember
- An editor writes code; an IDE also builds, runs and debugs it.
- Shortcut: check you have an editor, a compiler and a debugger.
- Trap: a Run button is only a shortcut for a compiler command.
