C++ Development Configuration (iOS and Chrome OS)

If you’re limited to programming on a Chromebook or an iOS device, not much programming software can be installed, unfortunately. Luckily, websites have been made to allow you to program online.

Whenever we run C++ code, it first must be converted to code that your computer can understand. This is the job of the C++ compiler. Usually, programming in C++ requires you to install a C++ compiler to your own computer, which you’re unable to do in iOS and Chrome OS. Therefore, all of your programming will have to be done using an online compiler. My favorite is at repl.it.

To test your online compiler out, remove any code that’s currently in the code file, and replace it with this:

#include <iostream>

int main() {
    std::cout << "Hello world!\n";
    return 0;
}

To run the program with repl.it, press the green run button in the top middle of the screen. If all went well, you should see “Hello world!” printed to the black console window on the right.

It’s perfectly fine if you don’t know exactly what this program is doing right now. In the next page of this C++ guide, I’ll go through the code line-by-line and explain how it all works.