1/101
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai | Chat |
|---|
No analytics yet
Send a link to your students to track their progress
Computer
A programmable machine designed to follow instructions
Program
A set of instructions stored in a computers memory that makes a computer perform a task
Hardware
The physical components that make up a computer system
Central Processing Unit (CPU)
The central part of the computer that fetches instruction, decoded them , and carries out the commanded operations
Control Unit (CU)
A component of the CPU that retrieves and decodes program instructions and coordinates all other computer activities
Arithmetic & Logic Unit (ALU)
A component of the CPU optimized for high-speed numeric calculations and true/false or yes/no decisions
Main Memory/ Random Access Memory (RAM)
Volatile temporary workspace memory that holds active programs and data while the computer is running
Bit
The smallest piece of memory, holding a value of either 0 (off, false) or 1 (on, true)
Byte
A group of 8 consecutive bits, which serves as the base unit for memory addressing
Address
a unique number assigned to each individual byte in memory to identify its location
Secondary Storage
Non-volatile storage (keeps data stored permanently) used to retain data even when the computer is turned off
Input Devices
Physical hardware (keyboard, mouse, digital camera) that sends information to computer from the outside
Output Devices
Physical hardware (monitor, printer) that presents information or processed results from the computer to the user
Software
Programs that run on a computer; categorized into System Software (like operating systems) and Application Software (like games or word processors)
Algorithm
A set of well-defined steps for performing a task or solving a problem
Machine Language
The Low-Level binary numbers (0s and 1s) that a computer’s hardware can directly execute
Low-Level Language
A programming language used to communicate with the computer hardware directly, often written in binary code
High-Level Language
A programming language designed to be closer to human language for easier writing and reading
Source File/ Source Code
The file containing the original, high-level statements written by the programmer using a text editor (the whole file, ex: .cpp)
Preprocessor
A program that converts source file directive into modified source code statements before compiling
Compiler
A program that translates modified high-level source code statements into binary machine instructions (object code)
Linker
A program that connect hardware-specific code and runtime libraires to machine instructions, producing the final executable file
Integrated Development Environment (IDE)
A single software application that combines all the necessary tools to write, compile, and debug a program.
Key Words (reserved words)
Words that have a special meaning in a programming language and cannot be used for any other purpose.
Programmer-Defined Identifiers
Names made up by the programmer to represent variables, functions, or memory locations that are not part of the core language.
Operators
Symbols or characters used to perform operations on data (such as arithmetic operations or assignment operations).
Punctuation
Characters (like commas or semicolons) used to mark the end of a statement or separate items in a list.
Syntax
The explicit grammar and structural rules that must be followed when constructing a program.
Variable
A named location in the computer's memory used to hold a piece of data.
Comment (//)
Text written into a program for documentation that is ignored by the compiler.
Preprocessor Directive (#include)
An instruction that tells the preprocessor to insert the contents of another file (like <iostream> or <string>) into the program before compilation begins.
Namespace
A feature that organizes code elements into logical groups to prevent naming conflicts
Main Function
The starting point of execution for every C++ program. (int main)
Code Block
Encloses a group of program statements, defining the beginning and end of a function or structure. ({})
String Literal
A hardcoded sequence of characters enclosed in double quotation marks. (““)
Semicolon
The character used to mark the end of a programming statement.
cout Object
The standard output stream object used to display data on the computer screen.
Stream insertion operator («)
The operator used to send data or strings to the output stream object (cout).
Manipulator
A stream manipulator used to insert a newline character and flush the output buffer. It must not be enclosed in quotes. (endl)
Escape Sequence
A special character sequence placed inside a string literal to start a new line of output. (\n)
Variable
A named storage location in the computer's memory that has a specific data type and must be defined before use.
Literal
A fixed value written directly into the program's source code (e.g., an integer literal like 12 or a character literal like 'A').
Identifier
A programmer-defined name given to program elements like variables or functions. It must begin with a letter or underscore and is case-sensitive.
Integer Data Types (int)
A data type used to store whole numbers (both positive and negative) without fractions.
Character Data Types (char)
A data type used to hold single characters or very small integers, typically taking up 1 byte of memory and storing the character's underlying numeric code.
Character Literal
A single character enclosed in single quotation marks.
Null Terminator (\0)
A hidden character automatically appended to the end of character strings in memory to mark the string's end.
string Class
A special C++ data type (requiring #include <string>) that provides extensive support for working with and manipulating sequences of characters.
Float
A single-precision floating-point type.
double
The default double-precision floating-point type.
long double
An extended-precision floating-point type
Floating-Point Literal
A fractional value written directly into the code. Can be written in Fixed point notation (e.g., 31.4159) or E notation (scientific notation, e.g., 3.14159E1). They are double by default unless forced with a suffix (f for float, L for long double).
bool Data Type
A data type representing boolean values that are either true (stored internally as 1) or false (stored internally as 0).
auto Key Word
A C++11 feature that tells the compiler to automatically determine a variable's data type based on its initialization value.
sizeof Operator
An operator used to determine the size (in bytes) of any data type or variable.
Assignment Operator (=)
Stores a value in a variable. The variable receiving the value must always be on the left side of the operator (e.g., item = 12;).
Variable Initialization
Assigning a value to a variable at the exact moment it is defined (e.g., int length = 12;).
Scope
The specific part of a program where a variable is accessible. A variable cannot be used before it is defined/declared.
Unary Operator
An operator that requires exactly one operand (e.g., the negative sign in -5).
Binary Operator
An operator that requires two operands (e.g., 13 - 7).
Ternary Operator
An operator that requires three operands (e.g., exp1 ? exp2 : exp3).
Division Operator
Performs integer division (discards the remainder) if both operands are integers (e.g., 13 / 5 is 2). It returns a floating-point result if at least one operand is a float or double (e.g., 13 / 5.0 is 2.6).
Modulus Operator
Computes the remainder of integer division (e.g., 13 % 5 is 3). It strictly requires both operands to be integers.
Single-Line Comments
A comment starting with // that documents code through to the end of that specific line.
Multi-line comments
A comment block starting with /* and ending with */ that can span across multiple lines.
Named Constant
A variable whose content is read-only and cannot be changed during program execution. It is declared using the const keyword and is traditionally named using uppercase letters.
Programming Style
The visual organization of source code (using spaces, tabs, and blank lines). It does not change how code runs, but it directly impacts readability for humans.
cin Object
he standard input stream object used to read data entered from the keyboard. It requires the <iostream> header file.
Stream extraction operator (»)
The operator used to retrieve information from cin and store it into one or more variables.
Mathematical Expression
A literal, a variable, or a mathematical combination of constants and variables (e.g., 2 * PI * radius).
Associativity
The order in which operators of the same precedence level are evaluated (e.g., unary negation associates right-to-left, while + and - associate left-to-right).
pow(base,exponent)
A built-in C++ function used for exponentiation, since C++ lacks a dedicated algebraic exponent operator.
Type Coercion
The automatic conversion of an operand's data type by C++ to match another type during an operation.
Promotion
A form of type coercion where a data type is automatically converted to a higher, more complex type (e.g., int to double).
Demotion
A form of type coercion where a value is forced into a lower data type, which can lead to data truncation.
Hierarchy of Types
The ranking of data types by the size of the numbers they can hold. long double sits at the highest rank, while int sits at the lowest rank.
Overflow/Underflow
A critical runtime error or calculation distortion that occurs when a value is assigned to a variable that is too large (overflow) or too small (underflow) for its data type capacity. This causes the value to "wrap around" into incorrect values.
Type Casting
The process of explicitly and manually converting a value from one data type to another.
static_cast<type>value
The preferred, modern C++ standard operator used to perform safe, manual type conversions (e.g., converting an int calculation to a double for fractional division).
C-Style Cast
An older, inherited casting syntax where the target data type name is placed inside parentheses before the value (e.g., (int)ch).
Prestandard C++ Cast
An older casting syntax where the value being converted is enclosed in parentheses after the type name (e.g., int(ch)).
Multiple Assignments
Using the assignment operator multiple times in a single line to assign the same value to several variables at once (e.g., x = y = z = 5;), executing from right to left.
Combined Assignment Operators
Shorthand assignment operators (+=, -=, *=, /=, %=) that perform an arithmetic operation on a variable and immediately assign the result back to that same variable (e.g., x += 5; is equivalent to x = x + 5;).
Formatting Output
The process of controlling how numeric and string data is visually laid out on the screen (such as sizing, positioning, and decimal precision).
Stream Manipulators
Specialized functions or symbols used within a cout statement to alter the format of the output stream. They require the <iomanip> header file.
setw(n)
A stream manipulator that establishes a print field at least n spaces wide. It only affects the very next value displayed.
fixed
A stream manipulator that forces floating-point numbers to display in fixed-point decimal notation rather than scientific notation.
setprecision(n)
A stream manipulator that sets the number of digits displayed for floating-point values. When used alongside fixed, it controls the number of digits after the decimal point. Without fixed, it controls total significant digits
showpoint
A stream manipulator that forces a decimal point and trailing zeros to display for floating-point values, even if the number has no fractional part.
left
A stream manipulator that causes subsequent output to be left-justified within its specified print field.
right
A stream manipulator that causes subsequent output to be right-justified within its specified print field.
getline()
A built-in C++ function used to read an entire line of text into a string object, ensuring that spaces and whitespace characters are not skipped over or ignored.
cin.get(ch)
A stream member function used to read a single character from the input buffer and store it in variable ch. Unlike standard cin >>, it successfully reads whitespace characters like spaces, tabs, and newlines.
cin.ignore()
A stream member function used to skip over and discard unneeded characters left over in the keyboard buffer (e.g., cin.ignore(10, '\n') skips up to 10 characters or until a newline is reached).
length Member Function
A function belonging to the string class used to determine the total number of characters contained inside a string variable.
String Concatenation (+ / +=)
The process of joining two or more string objects together into a single sequence of characters.
<cmath> header file
The library file required to access standard math functions which typically accept a double value as input and return a double.
(sin / cos / tan: Trigonometric functions for calculating Sine, Cosine, and Tangent. sqrt: Calculates the square root of a number. log: Calculates the natural (e) logarithm. abs: An integer-based function that calculates and returns the absolute value of a number.)
<cstdlib> Header File
The library file required to access random number generation functionality.
rand()
Returns a pseudo-random integer between 0 and the computer's maximum integer limit (RAND_MAX).
srand(x)
Accepts an unsigned integer x to seed and initialize the pseudo-random number generator, preventing it from yielding the identical sequence every run.