Fastest way to convert a number in other base to decimal number in Linux
Use Bash's arithmetic expression and expansion echo $((<BASE>#<NUM in that BASE>))
` can quicikly convert any number in other base to a decimal number.
For example
echo $((2#101010))
will give 42
echo $((16#AAAA))
will give 43690
Written by Techlive Zheng
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Shell
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#