expr is another command that is used to evaluate arithmetic expressions similar as ‘let’ command.
But expr can’t define variables.
expr command is working as following example.
num1=1
num2=2
expr $num1 + $num2
Important :
In expr command multiplication works different way. That means this is not working.
2 * 3
Have to type '\*' to get the multiplication
2 \* 3
Thursday, August 7, 2008
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment