Thursday, July 14, 2016

Shell Script Basic Code Examples(4)

Smiley face

Code:Method

Smiley face

Output:

Smiley face


Code:Method with Arguments

Smiley face

Output:

Smiley face

Note

first argument is "$1" then "$2","$3"...




Code:Method with return

Smiley face

Output:

Smiley face

Note

Can't return string only numeric

"$?":give the exit status of last command executed




Code:Method with operations

Smiley face

Output:

Smiley face

No comments:

Post a Comment

Wel Come !!! computer express