I am really confused in arrays and pointers.
Please tell me What is difference between following two codes?
int main() { int i,*p; for(i=0;i<5;i++) { p[i]=i; printf("%d",p[i]); } return 0; } int main() { int i,p[5]; for(i=0;i<5;i++) { p[i]=i; printf("%d",p[i]); } return 0; }