Algorithms are used to help design programs that perform particular tasks.
Selection is a decision or question.
At some point, a program may need to ask a question because it has reached a step where one or more options are available. Depending on the answer given, the program will follow a certain step and ignore the others.
Many solutions feature several choices or decisions. These decisions lead to different paths through the program. These paths represent the result of making a choice. Without selection it would not be possible to include different paths in programs, and the solutions we create would not be realistic.
Once an algorithm has been designed and perfected, it must be translated – or programmed – into code that a computer can read.
Selection is implemented in programming using IF statements.