If I type g++ main.cpp functions.cpp into the terminal followed by ./a.out, nothing happens. No errors nothing.
I have followed this part of the VS Code instruction in particular " You can modify your tasks.json to build multiple C++ files by using an argument like "${workspaceFolder}\\*.cpp" instead of ${file} . This will build all .cpp files in your current folder."
Has anyone made a comprehensive guide on transitioning from solely using the Codecademy site to another IDE? I feel like this is pretty essential knowledge for getting a job?
I’m not sure how good the basic support is for C/C++ on vs code. It’s arguably still a text editor so it relies on you to set up quite a few things. You might have an easier time with a more complete IDE since you get the nice GUI and so on. That’s not to say you can’t use vscode but it may take more effort on your part to get the right customisation going.
If you get the chance it might be worth having a little look into learning more about the command line/shell. Unfortunately many languages still rely on a certain level of knowledge about it, especially when you’re building bigger projects and trying to tie several things together. Languages like C/C++ in particular require you to know a little something the filesystem and paths/environment variable for the sake of including the right things.
The way you describe it though,
If I type g++ main.cpp functions.cpp into the terminal followed by ./a.out, nothing happens. No errors nothing.
I’m not sure the editor settings are the problem. Do you have any output statements in main? It might be worth adding some for now if only for the sake of simple debugging.
Could you perhaps share the relevant code snippets, even if it’s a cut back version for “hello world” or something?
When you try compiling multiple files do you get an output file ? try adding -oname to the g++ line this should produce a file called name (use mycode.exe for example) then check that you have the file. If this is the case then try a simple multifile project that just prints stuff to the screen to see what happens.