#include<iostream>
#include<iomanip>
int main()
{
int a(78);
//to get the hexadecimal equivalent we can have
std::cout<<std::hex<<a<<std::endl;
//the result would be 4e.
Ok good, now my question is, Instead of std::cout-ing the result, is it possible to assign the result to either a char or string variable?