How Do I Christen This Class?
Good design goes hand in hand with the nomenclature it uses for exchanging that design between developers. A key feature to writing good code consists of good naming conventions and
Good design goes hand in hand with the nomenclature it uses for exchanging that design between developers. A key feature to writing good code consists of good naming conventions and
It is an error to call the member function pop() on an empty stack. If you are not sure whether a stack contains any elements, you can use the member
An uninitialized pointer has an indeterminate value. It’s almost impossible to test subsequently whether such a pointer is valid, especially if it is passed as an argument to a function,
When creating menu items and adding them to a menu, you can shorten your code by combining two steps into one. Instead of creating the menu item and adding it
C and C++ make a clear-cut distinction between two types of pointers: data pointers and function pointers. A function pointer embodies several constituents such as the list of arguments, a
A pure virtual function is merely an interface and can be thought of as a way to enforce policy. A pure virtual function should be used when subclasses implement the
You can use affixes to help the compiler figure out the correct type of a hard coded integer. The letter L affixed to a number indicates a long integer and
An elaborated type specifier is a type name preceded by one of the keywords: enum, struct, union, and class. You can use an elaborated type specifier to instantiate an object
Standard C defines the function bsearch, which performs a binary search on an array of elements. The function bsearch is very efficient, but it works only on sorted arrays. You