Re: BASH question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Andy Green wrote:
> M.Lewis wrote:
>>
>> I thought this was simple, but I've not yet been able to figure out
>> what is wrong.
>>
>> #!/bin/sh
>>
>> PERMINUTE=$((28.95/432000))
> 
> No floating point support :-)  But even then, be liberal with spaces
> 
> PERMINUTE=$(( 29 / 432000 ))

Right...and since bash only works with integers the result of this
calculation is "0".

-- 
 "Who would have though hell would really exist? And that it would be in New
Jersey?" -Leela
"Actually..." - Fry


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux