let's use my code as an example
PHP Code:
#include <stdio.h>
int main(void){
int *a,*b; /*creates two pointers*/
int c[]={0,1,2,3,4,5}; /*an array*/
int d[]={1,2,3,4,5,6}; /*another*/
a=c; /*a now pionts to c*/
b=d; /*b now points do d*/
*a++=*b++; /*equivalent to *a=*b; a++;b++;*/
/*the assignment is first then the ++
are done afterwards. the reason they
are *sort of* equal is in the assignment*/
/*a[i]=b[i] is equal to *a=*b; they are sort
of because a and b are incremented after-
wards in our example; we don't need a temp variable*/
printf("a == %d\nb == %d\nc == %d\n",*a,*b,c[0]);
return 0;
}
PHP Code:
/*My output*/
a == 1
b == 2
c == 1
Do you understand