用命令行新建C文件

touch hello.c

编辑C文件

vim hello.c

编写C程序代码

#include <stdio.h>int main(){    printf("Hello World!");    return 0;}

编译C程序文件

cc -c hello.c

生成可执行文件

cc hello.o

执行文件

./a.out