Why did C++11 introduce the nullptr constant when we already have NULL?
What will be an ideal response?
nullptr gives us type safety. NULL is used semantically as an empty pointer,
but the compiler also treats it like the number 0. This means a 0 can be substituted
anywhere for NULL. This could cause problems if we ever need to differentiate between
0 and the empty pointer. nullptr solves this problem because it is not the same as 0. It
is a new constant that represents an empty pointer.
Computer Science & Information Technology
You might also like to view...
What does the Spanning Tree Protocol do?
What will be an ideal response?
Computer Science & Information Technology
The Dreamweaver ________ is designed to provide the user with easy access to all the tools needed to create web pages.
Fill in the blank(s) with the appropriate word(s).
Computer Science & Information Technology