Chapter 2 Programming Basics Flashcards
What are comments?
Text in a coding file not read in the compiler.
What are directives?
Instructions given to the compiler to perform a specific task (e.g. libraries).
Keywords/Reserved Words
Words that have been predefined by C++ and can not be given a new meaning.
What are identifiers?
These are words that are programmed that have their own meanings.
What are literals?
Literals are values coded into the language that only have one possible value.
Operators
Symbols used to indicate an operation being performed.
What are libraries and their two parts?
Libraries are files with created functions. The interface is the header file before the main function and the implementation are the different functions utilized within the main function.
What is preprocessing for?
To link all the header files to make a valid program.
What happens in the compiling stage?
The code is translated into machine language line by line checking errors.
What is linking?
Putting the preprocessing materials and the compiled code together.
What are atomic and composite data types?
Atomic data types hold one piece of information that can not be split. Composite data types are comprised of several pieces of atomic data.
What is a Boolean type?
The bool type can hold either true or false, taking one byte.
What is the char data type?
Holds one character using one byte. Signed: -128-+127 Unsigned: 0-255
What is a short data type?
Can store small integers using 2 bytes.
Signed: -32768-+32767 Unsigned: 0-65535
What is the int data type?
The integer data type uses for 4 bytes and is the standard data type. Signed: -32768-+32767 Unsigned: 0 - 65535