linux,怎么运行程序?
时间:2011-08-18
来源:互联网
是linux centos5.3的系统
[root@localhost testC]# gcc -o helloWorld helloWorld.c
[root@localhost testC]# ls -al
total 40
drwxr-xr-x 2 root root 4096 Aug 18 13:38 .
drwx------ 4 ssl ssl 4096 Aug 18 13:29 ..
-rwxr-xr-x 1 root root 4752 Aug 18 13:36 a.out
-rwxr-xr-x 1 root root 4752 Aug 18 13:38 helloWorld
-rw-r--r-- 1 root root 76 Aug 18 13:36 helloWorld.c
-rw------- 1 root root 12288 Aug 18 13:31 .helloWorld.c.swp
[root@localhost testC]# helloWorld
-bash: helloWorld: command not found
请问为什么我输入helloWorld会command not found
我要怎么执行helloWorld呢 ?
小弟分少,问题多。所以。。。还请大家帮帮忙。
[root@localhost testC]# gcc -o helloWorld helloWorld.c
[root@localhost testC]# ls -al
total 40
drwxr-xr-x 2 root root 4096 Aug 18 13:38 .
drwx------ 4 ssl ssl 4096 Aug 18 13:29 ..
-rwxr-xr-x 1 root root 4752 Aug 18 13:36 a.out
-rwxr-xr-x 1 root root 4752 Aug 18 13:38 helloWorld
-rw-r--r-- 1 root root 76 Aug 18 13:36 helloWorld.c
-rw------- 1 root root 12288 Aug 18 13:31 .helloWorld.c.swp
[root@localhost testC]# helloWorld
-bash: helloWorld: command not found
请问为什么我输入helloWorld会command not found
我要怎么执行helloWorld呢 ?
小弟分少,问题多。所以。。。还请大家帮帮忙。
作者: a34020249 发布时间: 2011-08-18
若要执行现行目录下的程序,使用./helloWorld
作者: keyoflov 发布时间: 2011-08-18
相关阅读 更多
热门阅读
-
office 2019专业增强版最新2021版激活秘钥/序列号/激活码推荐 附激活工具
阅读:74
-
如何安装mysql8.0
阅读:31
-
Word快速设置标题样式步骤详解
阅读:28
-
20+道必知必会的Vue面试题(附答案解析)
阅读:37
-
HTML如何制作表单
阅读:22
-
百词斩可以改天数吗?当然可以,4个步骤轻松修改天数!
阅读:31
-
ET文件格式和XLS格式文件之间如何转化?
阅读:24
-
react和vue的区别及优缺点是什么
阅读:121
-
支付宝人脸识别如何关闭?
阅读:21
-
腾讯微云怎么修改照片或视频备份路径?
阅读:28