Computational Thinking is how we solve problems so computers can help us.
Computational Thinking
Decomposition
Breaking a big problem down into smaller, manageable parts.
Pattern Recognition
Spotting similarities or trends to help solve the problem.
Abstraction
Focusing on the important details and ignoring the rest.
Algorithms
Creating a step-by-step set of rules to solve the problem.
Algorithms
An algorithm is like a recipe.
Key Features:
- Must be precise.
- Must be in the correct order.
- Must have a clear end.
Flowcharts
Start/End
Terminator
Process
Action / Instruction
Input
Input / Output
?
Decision (Yes/No)
Debugging
Debugging is finding and fixing errors.
Types of Errors:
- Logic Error: The code runs, but does the wrong thing (e.g., turning Left instead of Right).
- Syntax Error: Spelling or grammar mistake (computer can't understand).
Logic
Computers use Boolean logic.
TRUE or FALSE
There is no "maybe"!