Term
|
Definition
4 bytes
Holds integer values |
|
|
Term
|
Definition
2 bytes
Holds a single keystroke. |
|
|
Term
|
Definition
8 bytes
Holds decimal numbers. |
|
|
Term
|
Definition
4 bytes
Holds decimal nubmers. |
|
|
Term
What is the difference between:
unsigned int temperature;
and,
int temperature; |
|
Definition
unsigned int only holds positive integers,
while int holds both negative and positive. |
|
|
Term
|
Definition
The "string" data type is used for words. |
|
|
Term
int *ptr;
double *pointer;
float *number; |
|
Definition
1 byte.
Pointers can only point to memory addresses.
They are declared by placing an asterisk before the identifier:
int *ptr;
double *pointer;
float *number; |
|
|
Term
Will the following code allow the user to enter his first name, a space, and his last name?
string fullName;
cin >> fullName; |
|
Definition
No.
"cin >> fullName" allows for one word without spaces.
If spaces are desired, the code must be:
getline(cin, fullName); |
|
|
Term
|
Definition
ofstream is a special data type that allows the user to write to a file. |
|
|
Term
|
Definition
ifstream is a special data type that allows the user to read in from a file. |
|
|