#include using namespace std ; //----------------------------------- union test { char ch ; int x1 ; }; //----------------------------------- int main() { test unionObject ; unionObject.x1 = 32771 ; unionObject.ch = 97 ; cout << unionObject.x1 << " : " << (int) unionObject.ch << endl ; return(0) ; } //-----------------------------------