简体   繁体   中英

Error with simple “Hello World” with Bash

I have the following error

bash: ./helloworld.sh: No such file or directory

while executing the following Bash script:

#!/usr/bin/bash
#this is a helloworld programme
echo" hello world"

I checked this bash and it is correct

Looks like you try to run following: echo "hello world" , but you wrote echo" hello world" , which is same as "echo hello world" . Spaces are important.

But also looks like you are also running a wrong script...

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM