Answers for "sum bash"

0

sum column bash

paste -sd+ infile | bc
# Using existing file
Posted by: Guest on October-29-2020
0

sum column bash

<cmd> | paste -sd+ | bc
# Using stdin
Posted by: Guest on October-29-2020
0

sum bash

#Just use following structure for summing up varibles:
sum=$((var1 + var2))
#For float numbers use next instruction:
sum=$(bc <<< $var1'+'$var2)
Posted by: Guest on December-17-2020

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language