c++ function to find datatype code example Example: how to know datatype of something in c++ int k; cout << typeid(k).name() << endl;