1/27
Practice flashcards covering core C++ foundations, Big-O complexities, data types, functions, pointers, arrays, and structs from the CS 213 Midterm Practice questionnaire.
int main()
The entry point of a C++ program.
double
A C++ data type appropriate for representing decimal numbers requiring greater precision.
Integer Division
Arithmetic division where both operands are integers, causing the fractional part to be truncated (for example, 10/3=3).
Modulus Operator (%)
An arithmetic operator that returns the remainder of an integer division.
Abstract Data Type (ADT)
A specification of a data type that defines what operations can be performed, rather than their implementation details or memory allocation.
Address-of Operator (&)
An operator used to obtain or return a variable's memory address.
Dereference Operator (*)
An operator used to access or modify the value stored at a valid pointer's memory address.
Arrow Operator (->)
An operator used to access a struct member through a pointer.
Identifier
A user-defined name given to a variable or function in C++.
Keyword
A reserved C++ word with a predefined meaning, such as int, while, or return.
char
A data type used for storing a single character enclosed in single quotation marks.
Equality Operator (==)
A comparison operator used to test whether two values are equal.
Logical AND (&&)
A logical operator that evaluates to true only when both given conditions are true.
Function
A reusable block of code designed to perform a specific task.
Parameter
The placeholder variable declared in a function definition.
Argument
The actual value passed to a function when it is called.
Pass-by-value
A parameter-passing mechanism that sends a copy of the original variable to a function, ensuring changes inside the function affect only the local copy.
Pointer
A variable that stores the memory address of another variable.
Array
A collection of elements of the same type stored in contiguous memory locations.
Array Traversal
The process of visiting each element of a data structure sequentially to inspect or display it.
Linear Search
A search method that examines elements of a collection sequentially until a target is found.
Constant Time (O(1))
A time complexity classification where runtime remains constant as input size grows, such as directly accessing an array element by index.
Linear Time (O(n))
A time complexity classification where runtime grows proportionally to the input size, typical of a single loop processing n elements.
Quadratic Time (O(n2))
A time complexity classification commonly resulting from two nested loops that each run n times.
Auxiliary Space
The extra memory needed by an algorithm to execute, excluding its original input space.
struct
A user-defined data type in C++ grouping related members together, possibly of different types, whose definition ends with a semicolon.
Dot Operator (.)
The operator used to access a member of a regular struct instance (such as student.name).
Array Decay
The conversion where arrays passed to functions decay to pointers, requiring the size of the array to be passed as a separate parameter.