0
Hello I took my quiz earlier and I'm kind or curious why I got this question wrong on pointers
Given the following two statements, how might you change the value of a to 4? double a = 3; double *p = &a; Â Â &p = 4; Â Â Â *p = 4; Â Â Â p->a = 4; (I selected this one because I assumed that double *p = &a a=4; Â Â Â ++p; Â Â Â It is not possible to change a by using p Â
1 Answer
0
*p = 4;
This mean "change the value pointed to by p".