what does this code do?
i thought the compiler copies the elements from y[i-1] to y[i] (just like memcpy()), my friend means the compiler changes only the references from y[i-1]->y[i]. or, in other case, what does y[i] supplies, the address of the element or the whole struct?Code:struct x { int a[5]; int b[5]; }; struct x y[10]; void rotate(void) { int i; struct x temp; temp=y[9]; for (i=9; i; i--) y[i]=y[i-1]; y[0]=temp; }