Term
Why is a pointer always an integer? |
|
Definition
A pointer is an address in memory, which is a hexadecimal number |
|
|
Term
How to change a pointer's value (2) |
|
Definition
1. Dereference it 2. Make it point somewhere else (with a double pointer) |
|
|
Term
|
Definition
An array is a pointer to its first element. When you pass an array as an argument, you lose its dimensions, so you can't use sizeof(). It will only pull the size of its first element. |
|
|
Term
|
Definition
|
|
Term
Why does C have outputs as function inputs and use return to indicate errors? (2) |
|
Definition
1. C does not have exceptions 2. Speed. Returning an output means making a copy of the output. |
|
|
Term
|
Definition
A global variable that contains the last error number |
|
|
Term
|
Definition
Converts errno into words perror("open") open: No such file or directory |
|
|
Term
How to deal with array/pointer decay (2) |
|
Definition
1. Pass the size of the array into the function as an argument 2. Put an identifier at the end of the array so we know where it ends as we iterate through |
|
|
Term
|
Definition
|
|
Term
|
Definition
|
|
Term
|
Definition
|
|
Term
|
Definition
|
|
Term
C-strings: unsigned integer |
|
Definition
|
|