"Newbie" question:
I'm learning some C++ at university, so I installed Xcode on my mac in order to compile and run my small programs.
There is absolutely no issue as long as I work within Xcode projects, that is to say writing and running "within Xcode".
Instead, I can't manage to compile (and run) them directly from the terminal window because, if I type "g++ file_name.cpp", I get the answer "-bash g++ command not found"; the same happens with gcc.
I thought that installing Xcode would provide me automatically with a proper compiler.
Can you help me?
PS: there are some similar threads but I couldn't find another user with exactly my same problem...
I'm learning some C++ at university, so I installed Xcode on my mac in order to compile and run my small programs.
There is absolutely no issue as long as I work within Xcode projects, that is to say writing and running "within Xcode".
Instead, I can't manage to compile (and run) them directly from the terminal window because, if I type "g++ file_name.cpp", I get the answer "-bash g++ command not found"; the same happens with gcc.
I thought that installing Xcode would provide me automatically with a proper compiler.
Can you help me?
PS: there are some similar threads but I couldn't find another user with exactly my same problem...