create new project -> mac os x下application -> command line tool -> next -> productName&type [c++] -> next 编写完代码后点击左上角三角run就行了,或者command+B编译,或者直接command+R 运行