Base Conversion: Hex and Oct to Decimal (w/negatives)
Posted: Wed Oct 19, 2005 6:43 pm
Hey,
For my current project I need to have hex to dec and oct to dec converters. I've manged to make my own, but it only works with positive numbers (basically all I've done is convert the hex number to its binary equivilant, then convert that to decimal - ok it's not perfect but it works for me).
So, any ideas on how to achieve this?
For my current project I need to have hex to dec and oct to dec converters. I've manged to make my own, but it only works with positive numbers (basically all I've done is convert the hex number to its binary equivilant, then convert that to decimal - ok it's not perfect but it works for me).
So, any ideas on how to achieve this?