include stdio int main int 10 10 int for 10 printf gcc -c main -o main

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#include <stdio.h>
int main()
{
int x[10] = {10};
int i;
for(i = 0; i < 10; i++)
printf("x[%d] == %d == %d\n", i, x[i], i[x]);
}
% gcc -c main.c -o main.o
% gcc main.o -o main
%./main
x[0] == 10 == 10
x[1] == 0 == 0
x[2] == 0 == 0
x[3] == 0 == 0
x[4] == 0 == 0
x[5] == 0 == 0
x[6] == 0 == 0
x[7] == 0 == 0
x[8] == 0 == 0
x[9] == 0 == 0