This is probably a fairly simple question but I cant seem to get it to work.
Im trying to multiply an entire column in a file by a variable in my bash script but just cant seem to get it to work with awk.
Here is what I'm trying
$varr is some value
$line is my file
awk '{print $1,$2*$varr}' $varr "$line"
It seems to print the $2*$varr 'th column instead of multiplying the $2 column by $varr
I've also tried such things as awk -v $varr the the rest of the stuff above, nothing seems to work.?