C++
C++ Chapter 1 — Must Know Tonight
Tier 1 — MUST MEMORIZE
These are the things I would be able to answer without thinking.
1. The 3 phases of software development
Development & Design → Documentation → Maintenance
⚠ Do NOT confuse this with the 4 steps of Phase I.
2. The 4 steps of Development & Design
Analyze → Develop → Code → Test
Analyze: Determine inputs and outputs
Develop: Create the algorithm
Code: Write the C++ program
Test: Find and correct errors
Easy memory:
A-D-C-T
Analyze → Develop → Code → Test
3. What is an algorithm?
An algorithm is a step-by-step sequence of instructions used to process data and produce the desired output.
It must terminate.
4. The 4 programming structures
Structure | Meaning |
|---|---|
Sequence | Instructions happen in order |
Selection | Choose between operations based on a condition |
Iteration | Repeat an operation based on a condition |
Invocation | Call/invoke a set of statements when needed |
Memory trick:
S-S-I-I
Sequence = order
Selection = choice
Iteration = repeat
Invocation = call
5. Testing vs. debugging
Testing: Determines whether the program works correctly and meets requirements.
Bug: An error in a program.
Debugging: Locate the error → correct it → verify the correction.
⚠ Testing can reveal errors, but it does NOT guarantee that there are no errors.
🟠 Tier 2 — VERY IMPORTANT
These are highly testable definitions/comparisons.
6. Software engineering
Software engineering focuses on creating programs/systems that are:
Readable + Efficient + Reliable + Maintainable
7. Computer program
A computer program is a self-contained set of instructions used to operate a computer and produce a specific result.
Also called software.
8. Pseudocode vs. flowchart vs. formula
Pseudocode → English-like description of an algorithm
Flowchart → Diagram showing an algorithm
Formula → Mathematical equation
9. Compiler vs. interpreter
Compiler
Translates all statements → stores executable/object program → executes later
Interpreter
Translates one statement → executes it immediately → moves to next
Memory trick:
Compiler = Complete first
Interpreter = Immediately
And remember:
C++ is predominantly compiled.
10. Low-level vs. high-level languages
Low-level
Closely tied to a particular computer.
Examples:
Machine language
Assembly language
High-level
More like human/written language and can work across different computer types.
Examples:
C
C++
Java
Visual Basic
11. Machine language
Machine language is the only type of program that can directly operate a computer.
It uses binary (0s and 1s).
12. Assembly language
Uses word-like symbols such as:
ADD
SUB
MUL
An assembler translates assembly language into machine language.
🟡 Tier 3 — KNOW THESE
13. Procedural vs. object-oriented programming
Procedural
Programs are organized around procedures/instructions.
Object-oriented
Programs use objects containing data and code that can be reused.
C++?
Both procedural AND object-oriented.
14. Application vs. system software
Application software
Used for specific user tasks.
System software
Operates/controls the computer system.
Example of system software:
Operating system
15. What does the operating system do?
Know these four:
Memory management
CPU-time allocation
Input/output control
Secondary storage management
16. Bootstrap loader → POST
When a computer starts:
Bootstrap loader → POST → boot process/system starts
POST = Power-On Self-Test
17. Hardware components
Know what each does:
ALU → Arithmetic and logic
Control Unit → Directs/monitors operations
Memory Unit → Stores instructions/data
I/O Unit → Communicates with peripheral devices
Secondary Storage → Permanent/nonvolatile storage
18. CPU
The CPU/microprocessor combines:
ALU + Control Unit
This is an easy quiz question.
🟢 Tier 4 — EASY POINTS
19. Bit vs. byte
Bit = smallest unit of data → 0 or 1
Byte = 8 bits → represents one character
20. ASCII
ASCII = American Standard Code for Information Interchange
It's a character code that represents characters using patterns of 0s and 1s.
21. Word
A word is a grouping of one or more bytes.
The number of bytes in a word affects the amount/range of data that can be stored.