conversion
I am writing code to convert a negative binary number to its positive counterpart. The code below doesn't do the conversion properley. Can anyone please help??
#define SIZE 8
void Converter(int binary[])
{
int num[SIZE];
for(count = SIZE - 1; count >= 0; cout--)
{
if(binary[0] = '1'); // is negative
sum[count] = 0; // this making everything to zero
} // end for
}
George N. Bilios
__________________
gbilios
|