Which statement about class unique_ptr (of the new C++ standard) and dynamic memory allocation is false?

a. An object of class unique_ptr maintains a pointer to dynamically allocated memory.
b. When a unique_ptr object destructor is called (for example, when a unique_ptr object goes out of scope), it performs a destroy operation on its pointer data member.
c. Class template unique_ptr provides overloaded operators * and -> so that a unique_ptr object can be used just as a regular pointer variable is.
d. Class unique_ptr is part of the new C++ standard and it replaces the deprecated auto_ptr class.


b. When a unique_ptr object destructor is called (for example, when a unique_ptr object goes out of scope), it performs a destroy operation on its pointer data member.

Computer Science & Information Technology

You might also like to view...

Consider the program below:

``` public class Test { public static void main(String[] args) { int[] a; a = new int[10]; for (int i = 0; i < a.length; i++) a[i] = i + 2; int result = 0; for (int i = 0; i < a.length; i++) result += a[i]; System.out.printf("Result is: %d%n", result); } } ``` The output of this program will be: a. Result is: 62. b. Result is: 64. c. Result is: 65. d. Result is: 67.

Computer Science & Information Technology

A tab stop should always be set for AutoNumber fields

Indicate whether the statement is true or false

Computer Science & Information Technology

What is it called when you can scroll through two documents at the same time using either of the two scroll bars?

A) Synchronized Scrolling B) Synchronous Scrolling C) Grouped Scrolling D) You cannot do this in Word.

Computer Science & Information Technology

________ is/are called Port-Based Access Control.

A. 802.11j and 802.1X B. 802.11i and 802.13x C. 802.11i and 802.1X D. 802.11i and ISO 27001

Computer Science & Information Technology