Hello
I am doing an C++ exercise and the task is to write a program that
prints all INT values between 32 to 255 and the corresponding ASCII characters.
I have declared the variables to store the ASCII character and the INT like this:
unsigned char unchar;
int i;
And the following statements within a FOR loop will do the print out:
unchar = i;
cout << setw(3) << i << " " << unchar << " ";
My question is why g++/LINUX development environment will print
a 'rubbish character`for the INT values between 128 and 255
while Visual C++ 2008 Express Edition run on Windows Vista
will print the characters that are requested in the task specification
with the same source code.
E.g 128 Ç 129 ü and so on.