Chapter 12 Pointers
( True/False ) A pointer is a reserved word
False
( True/False ) Dynamic variables are destroyed using the operator new
False
( True/False ) If a pointer p points to a dynamic array, the elements of p can be processed using a rang-based for loop
False
( True/False ) If p is a pointer variable, then the statement p = p * 2; is valid in c++
False
( True/False ) Pointer variables are declared using the word pointer
False
( True/False ) The address of operator returns the address and value of its operand
False
( True/False ) The binding of virtual functions occurs at compile time
False
( True/False ) The dereferencing operator has a higher precedence than the dot operator
False
( True/False ) The statement delete p; deallocates the variable pointer p.
False
What do pointers variables contain as their values?
The address of other variables
( True/False ) Given the declaration: int list[10]; int *p; the statement: p = list; is valid in C++
True
( True/False ) If p is a pointer variable, then *p refers to the memory location to which p points.
True
( True/False ) In a shallow copy, two or more pointers of the same type point to the same memory
True
( True/False ) No name is associated with the pointer data type
True
( True/False ) The return type of a function can be pointer
True
( True/False ) The statement delete p; deallocates the dynamic variable that is pointed to by p
True
( True/False ) Variables that are created during program execution are called dynamic variables
True
Given the declaration: int *p; the statement: p = new int[50]; dynamically allocates an array of 50 components of type int, and p contains the base address of the array
True