12 int valueToConvert = 0;
15 char HexValues[] =
"0123456789ABCDEF";
17 std::cout <<
"Enter a Decimal Value"
22 while (valueToConvert > 15) {
23 hexArray[i++] = valueToConvert % 16;
27 hexArray[i] = valueToConvert;
29 std::cout <<
"Hex Value: ";
30 while (i >= 0) std::cout << HexValues[hexArray[i--]];
32 std::cout << std::endl;