Dealing with int arrays in c++ -
i looking @ c++ code trying learn , came across strange , have no clue going on.
int a[100000]; int main() { int n; scanf("%d", &n); (int = 0; < n; i++) { scanf("%d", + i); }
i understand happening except scanf("%d", + i);
line happening array here? adding integer read in console array? have understanding of java.
so if able translate java. able understand happening.
a + i
same &a[i]
, or in other words, a[i]
same *(a + i)
. a + i
address of ith element (count starting @ zero).
Comments
Post a Comment