Tuesday, September 14, 2010

Quick and dirty hex converter

void convertHex()
{
    string exchangeHex = "0123";
    int exchange;

    //exchangeHex
    std::stringstream ss;
    ss << std::hex << exchangeHex;
    ss >> exchange;
 
    cout << exchange << endl;
}

No comments:

Post a Comment