The three modes
Settings exposes a compile & run mode with three options:
- Auto (default) — the desktop app first checks whether a C++ compiler is installed locally. If yes, it compiles locally; if not, the code is sent to the remote compile service. This is why the same installer can behave slightly differently across machines.
- Local — always use the local
g++. Compilation happens on your own PC with no network needed: ideal for individual study and debugging. - Remote — send the code to a remote compile service. The benefit is consistency across devices: machines without a local toolchain (lab images, tablets, locked-down PCs) still run exercises normally.
g++, remote mode compiles the same code on the service.Local compilation: what to install
- Install a GNU C++ toolchain for Windows (for example MinGW-w64, selecting
g++during setup). - Add the compiler's
binfolder to the systemPATH. - Restart KuaiJiZi C++ Tutor — detection happens at startup — and keep the mode on Auto or Local.
- Run a tiny program (for example printing one line) to confirm it compiles locally and outputs correctly.
Using a remote compile service
In remote mode you enter the service address in Settings — either an institution's self-hosted service or one you run yourself. Two things to keep in mind:
- Privacy: remote mode sends the code to that service. Exercise and teaching code is fine, but avoid submitting code containing sensitive information.
- Availability: a wrong address or a stopped service means the build fails. Switch to Local temporarily to keep the lesson going.
Troubleshooting
“No compiler found” / always using remote
The local g++ was not detected. Verify MinGW-w64 is installed and its bin directory is on PATH — g++ --version should print a version — then restart the app.
Build failed and the errors look cryptic
Read the first error only; later ones are often knock-on effects. Typical causes: a missing semicolon, unbalanced brackets, an undefined variable, or a missing header for cin/cout. If you built with blocks, compare against the generated code.
It compiles but the output is wrong
Compare expected and actual output line by line — extra spaces or line breaks count. Practice projects show a side-by-side diff in the check bar.
Remote service unreachable
Check the address in Settings and whether the network can reach it; switch to Local to continue, or ask your administrator about the service status.
Next: close the practice loop
Load a practice project, add reference-answer code and let the app check whether your output matches.