True or False int *p1; declares a variable whose memory is statically allocated.
ID: 3589706 • Letter: T
Question
True or False
int *p1; declares a variable whose memory is statically allocated.
Dynamically created variables have no name.
If p1 and p2 are both pointers that point to integers in memory, the condition p1==p2 will be true if the values that are stored in the dynamic memory locations pointed to by p1 and p2 are the same.
Even though pointers point to addresses which are integers, you cannot assign an integer to a pointer variable.
In the following statement, both variables are pointers.
int* p1, p2;
A contents of a pointer can be stored in an integer variable.
Explanation / Answer
int *p1; declares a variable whose memory is statically allocated--------->False Dynamically created variables have no name------------->True If p1 and p2 are both pointers that point to integers in memory, the condition p1==p2 will be true if the values that are stored in the dynamic memory locations pointed to by p1 and p2 are the same----->False Even though pointers point to addresses which are integers, you cannot assign an integer to a pointer variable----->True In the following statement, both variables are pointers int* p1, p2;----->True A contents of a pointer can be stored in an integer variable------->True
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.