2.1 Flashcards
1
Q
Abstraction (2)
A
- Removes unnecessary details
- To reduce the complexity when problem solving
2
Q
Decomposition (2)
A
- Breaking complex problem down into smaller more manageable parts
- Solving each small problem, one at a time (different people can work on different parts of a problem, reducing development time)
3
Q
Algorithmic Thinking Approach
A
- Identifying the individual steps needed to get to a solution
4
Q
Structure Diagrams (3)
A
- Illustrate decomposition
- To understand a problem to code
- Lowest level nodes achieve a single task
5
Q
Oval with Flat Sides
A
Terminal (e.g. start/end)
6
Q
Rhombus
A
Input/Output
7
Q
Sideways Diamond
A
Decision
8
Q
Line
A
Program flow (leading onto one thing, sometimes yes/no label)
9
Q
Medium Rectangle in a Big Rectangle (horizontal touching)
A
Sub routine
10
Q
Rectangle
A
Process (something is initialised/calculated)
11
Q
Syntax Errors (2)
A
- Break the grammatical rules of the language
- Stop it from being run
12
Q
Logic Errors (2)
A
- Produce unexpected output
- Won’t stop program running
13
Q
Trace Tables (5)
A
- Each line writing out the current state of each variable
- Noting down every output
- Each variable has own column
- New row every time state of variable changes
- Excellent way to track down logical errors
14
Q
Binary Search (5)
A
- Calculate mid point
- If item is lower than mid point, repeat on left side including mp
- If item is greater than mid point, repeat on right side including mp
- Repeat until item is found/no items left to check
- Requires data set to be in order
15
Q
Linear Search (3)
A
- Starting from beginning
- Does not require to be in order
- Very inefficient
16
Q
Bubble Sort (4)
A
- Sorts unordered list of items
- Compares each item with next and swaps when out of order
- Finishes when no more swaps need to be made
- Inefficient but easy to implement
17
Q
Merge Sort (3)
A
- Very efficient divide and conquer method for large data sets
- Creates two or more identical sub-problems from the largest problem, solving individually
- Adjacent lists combined to solve bigger problem
18
Q
Insertion Sort (2)
A
- Each item into correct position in a data set one at a time
- Useful for inserting items into an already sorted list