linux下写c语言代码

输入 yum -y install gcc gcc-c++ kernel-devel 命令,安装 gcc、c++ 编译器以及内核文件

 

vim test.c

 

:!q 退出

 

gcc test.c -o test && ./test

编译,输出可执行文件为test,执行该程序

posted @ 2021-09-08 07:16  MikeLi  阅读(63)  评论(0编辑  收藏  举报