Changing base of a number
Suppose we want to convert 0xFACE into decimal value.
'ibase' is input number base.
'obase' is output number base in ibase number.(10 is A in hexadecimal format).
'FACE' is the number.
when we dont specify any of the value, its assumed to be 10.
echo "ibase=16; obase=A; FACE" | bc
'ibase' is input number base.
'obase' is output number base in ibase number.(10 is A in hexadecimal format).
'FACE' is the number.
when we dont specify any of the value, its assumed to be 10.
Comments
Post a Comment