How can I compile/run C or C++ in Unix console or a Mac terminal?
(I know it, forget it, and relearn it again. Time to write it down.)
just enter in the directory in which your c/cpp file is.
for compiling and running c code.
$gcc filename.c $./a.out filename.c
for compiling and running c++ code.
$g++ filename.cpp $./a.out filename.cpp
"$" is default mac terminal symbol