My calculation is getting converted to integer by default(KSH)
0
votes
1
answer
101
views
I am assigning a decimal value to a variable which is an output from an oracle command. when I echo the variable I see the decimal value.
For example, echo $a is showing me .7214 but when I do calculations on this, it is defaulted to integer.
For example, b=$((a+(a*20/100))) is rounding to 1.
How do I avoid rounding this to integer.
Asked by RAJ
(1 rep)
Aug 25, 2021, 12:32 AM
Last activity: Aug 25, 2021, 06:02 AM
Last activity: Aug 25, 2021, 06:02 AM