You need to compile them into an executable…
Is this the first time you deal with a program split into more than one file?
Don't you use an IDE (Visual Studio, Code::Blocks…)?
That's the general process. Each cpp file compiles to an object (.o) file and those are then "linked" together into the executable (the last command). But you can actually compile it in one command like this:
The first way allows you to compile separate cpp files which is useful when you have a bunch of them, but the process is usually controlled by a makefile (or cmake or an ide, etc.).