Printing Array
Hello everyone,
I'd like to ask, how should I print an array?
I'm not sure which part is wrong though...
1 2 3 4 5 6 7 8 9 10 11 12 13
|
if (R%2==1) {
for (y=0; y<R; y++) {
for (x=0; x<C; x++) {
if (i=123) i=97;
t=(char)i;
a[x][y]=='t';
a[x+1][y]=='t';
i=i+1;
if (a[x][y]=='*') i=i+1;
}
}
}
printf("%a\n", a[x][y]);
|
If you want to print each element of the array you will probably need to move the printf() to inside the for() loop.
Topic archived. No new replies allowed.