+ 1
Does Int* p and int *p 2 different things?
3 Respostas
+ 11
They're mostly similar until you initialize a bunch of variables at once.
Attaching * to the type causes every variable you make in the statement to be a pointer.
Ex: int* ptr1, ptr2, ptr3;
Placing the * on the variable name makes that one a pointer, but not anything else.
Ex: int num1, *intPtr, num2;
0
thanks
- 1
no