Decomp and Abstra Flashcards
ALGORITHMS -
a set of instructions for solving a problem or completing a task.
ABSTRACTION
involves removing unnecessary detail from a problem so that you can focus on the essential components to add to a solution
Decomposition –
involves breaking down a large problem into smaller subproblems so they are manageable
Then the sub-problems can be broken down further until each small task is manageable
Advantages of Decomposition :
The problem becomes easier to solve when it consists of a number of small subtasks
or subprograms
Some subprograms may be reusable in other programs, saving development time
Smaller problems can be tested independently so easier to identify a problem.
Why are subprograms so useful
Reusability: Once written, a subprogram can be used multiple times in different parts of a program.
Modularity: It helps break a large program into smaller, more manageable chunks.
Readability and Maintainability: Smaller, focused subprograms make the code easier to read, understand, and debug.