//Where am I going wrong?
//I am trying to convert numbers from one base to
// any other base.
// Converts numbers from any base to any other base.
#include <iostream.h>
int main()
{
int i;
do
{
cout << "Enter a number:" << endl;
cin >> i ;
dec(cout); // Set output to decimal
cout << '\" << i << '\" << " = " << i;
oct(cout); // Set out put to octal
cout << " =0" << i;
hex(cout); // Set output to hex
cout << " = 0x" << i << '\n';
}while ( i != 0);
return 0;
}



LinkBack URL
About LinkBacks



)