; rather than .

This commit is contained in:
Jidong Xiao
2024-01-23 13:50:09 -05:00
parent 4f22b4ec7c
commit 70613fc5d6

View File

@@ -124,8 +124,9 @@ will assume NULL and nullptr are equivalent.
- Comparing a pointer to NULL is very useful. It can be used to indicate whether or not a pointer variable is - Comparing a pointer to NULL is very useful. It can be used to indicate whether or not a pointer variable is
pointing at a useable memory location. For example, pointing at a useable memory location. For example,
```cpp ```cpp
if ( p != NULL ) if ( p != NULL ){
cout << *p << endl. cout << *p << endl;
}
``` ```
tests to see if p is pointing somewhere that appears to be useful before accessing and printing the value stored tests to see if p is pointing somewhere that appears to be useful before accessing and printing the value stored
at that location. at that location.