echo Linux Command Cheatsheet

echo Linux Command used to output text to screen. This is available in most of the operating systems along with Linux systems.


echo [option(s)] [string(s)]


echo Hello World! #=> Hello World!
echo $x #=> 5
echo x value is $x #=> x value is 8
echo Hello \nWorld! #=> Hello
                    #   World!

Note: \n is for new line

echo Hello \tWorld! #=> Hello   World!

`Note: \t is for tab

echo * #=> Prints files and folders of current directory
echo *.txt #=> Prints all .txt files from current directory

┬ęCopyright 2020 OneCompiler | Privacy Policy | Terms & Conditions