Use LEFT and RIGHT arrow keys to navigate between flashcards;
Use UP and DOWN arrow keys to flip the card;
H to show hint;
A reads text to speech;
26 Cards in this Set
- Front
- Back
What is it when you see // words and what does it do |
When you see a // that signifies that the following after is a comment. It doesn’t affect the code. For short explanations. |
|
A blank line |
Have no effect on program. Simply improve readability of code |
|
int main () |
Initiates the declaration of a function. |
|
Function |
A function is a group of code statements which are given a name |
|
Preprocessor directives |
Lines that include in a program that begin with the character # they are invoked by the compiler to process programs before compilation |
|
<< |
cout |
|
>> |
cin |
|
“ “ |
Encloses a string of characters |
|
Variable |
A storage location in memory. Has a name and a type of data it can hold. |
|
Literal |
A value that is written into a programs code |
|
Identifier rules |
Back (Definition) |
|
char data type |
Used to hold character or very small integer values Usually 1 byte of memory |
|
What must character literals have |
Must be enclosed in single quote marks. i.e ‘A’ |
|
What must character literals have |
Must be enclosed in single quote marks. i.e ‘A’ |
|
A series of characters in consecutive memory locations: “Hello” |
Character strings |
|
What must character literals have |
Must be enclosed in single quote marks. i.e ‘A’ |
|
A series of characters in consecutive memory locations: “Hello” |
Character strings |
|
What are the three floating-point data types and what do they do |
Float Double Long double |
|
What are the three floating-point data types and what do they do? |
Float Double Long double They hold real numbers including decimals |
|
Assignment position |
Must appear on the left side of the = operator 12 = item; will not work |
|
Assignment position |
Must appear on the left side of the = operator 12 = item; will not work |
|
% operator |
Computers the remainder resulting from integer division cout >> 13 % 5; will display 3. 5 goes into 13 twice, remainder 3, answer 3 |
|
Begin with /* and end with */ |
Multi line comments |
|
Named Constants (constant variable) |
Variable whose content can not be changed during program execution. Used for representing constant values with descriptive names: const double TAX_MAIN Often named in uppercase letters |
|
Prompt |
A prompt is a message that instructs the user to enter data |
|
Combined Assignment |
sum = sum + 1; sum += 1; |