Syntax for performing bash simple math calculations
Hi all
I saw this somewhere, but can't remember where... What's the correct syntax for performing simple bash math calculations? For instance, I just want to dive 105 by 7, what should I write? |
Did you mean something like echo $((105 / 7)) or are you thinking of using bc ?
|
Try the bc command. It is a powerful calculator available on the command line.
For example you can do the following: bc <return> 3+4 <return> 7 For a more extensive documentation try "man bc". --- Stingrayon. |
Stingrayon, Homey, thanks alot for your help! :D
|
All times are GMT -5. The time now is 02:46 AM. |