Steps to write and execute a script
Note: In the last step you have to mention the path of the script if your script is in other directory.
Hello World script
Here we'll write a simple programme for Hello World.
First of all, create a simple script in any editor or with echo. Then we'll make it executable with chmod +x command. To find the script you have to type the script path for the shell.
Look at the above snapshot, script echo Hello World is created with echo command as hello_world. Now command chmod +x hello_world is passed to make it executable. We have given the command ./hello_world to mention the hello_world path. And output is displayed.