Echo Command Assignment Help

Assignment Help: >> Advanced Shell Scripts - Echo Command

Echo Command

This command writes each provided STRING to the standard output, within a space among each STRING and a new line after the last one.

Syntax

echo [OPTION]... [STRING]...

Shell command accepts the following options. This command is exclusively used in shell scripts.

-n         Disables output of trailing new line.  

-e         Enable interpretation of the subsequent backslash-escaped characters in each STRING: only in the case of LINUX                      

\a         alert (bell)                   

\b         backspace                   

\c         suppress trailing newline                    

\f          form feed                   

\n         new line                      

\r          carriage return            

\t          horizontal tab             

\v         vertical tab                 

\\          back slash                   

Let consider the following example

# echo hello welcome to the world of shell programming

hello welcome to the world of shell programming

# a=10

# name=sam

#echo the value of a is $a the value of a is 10

# echo The Name is $name

The Name is sam

# echo -e "hello \a"

The given syntax give an output will be hello with an alarm sound.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd