I've started on a course, and my computer gives me some other symbols than the rest of the group. When i execute the following:
_____________________________________________________________
#include <stdio.h>
void main()
{
int i, j;
printf(" \t0 1 2 3 4 5 6 7\n");
for (i=12; i<32; i++)
{
printf("%d%d\t", i/8, i%8);
for (j=0; j<8; j++)
{
printf("%c ", (char) (i*8+j));
}
printf("\n");
}
getchar();
return 0;
}_____________________________________________________________
I get this: houmaa.dk/1.PNG
but i should get this: houmaa.dk/2.PNG
It would be really helpful to solve this problem, because if i can't make programming at home.. I'm screwed...
Hope someone can, THX..
Jonas
Your output is correct. It's just that the two computers (or consoles) that ran the program are using different code pages.
The code page that generates your reference output seems to be code page 850.
You're using Windows, right? Control Panel, Regional and Language options, Advanced tab. On the drop box choose the language you'll need. Reboot and then go to the same dialog. Code page 850 in the list below should be enabled (not grayed out) and selected.
I'm very disappointed in whoever made that reference output. Teaching anything other than ASCII and Unicode should be considered a crime.
I found the code page 850 were not checked out.. So I did.. I tried to reboot..
but when i went back to the page code 850 it was still "greyed out"
(see picture 3 in the dropbox)