8

bc command acts strange on obase=10

view full story
linux-howto

http://stackoverflow.com – today i found the 'bc' linux command and found a strange behaviour when calculating with outputbase 10. echo "ibase=16;obase=9;AFBE" | bc 67638 echo "ibase=16;obase=11;AFBE" | bc 09 02 11 08 echo "ibase=16;obase=10;AFBE" | bc AFBE well, command 1 and 2 are correct, but the third command simply prints the inputvalue. echo "ibase=16;AFBE" | bc 44990 gives a correct result. Is there any reason in this behaviour? (HowTos)