Algorithms Flashcards
What is an algorithm?
An ordered set of unambiguous, executable steps that defines a terminating process
How could an algorithm be designed and viewed?
An algorithm is often designed and viewed using pseudocode or flowcharts
What is the difference between a While and Until loop?
While loops continue as long as a condition is true. Until loops will stop when a condition is met. The condition is expressed differently, one for continuation and one for termination
What is required to use recursion?
If termination conditions are not well set out, its possible a program may have an infinite loop which can lead to massive resources usage or crashes
What is the maximum number of time an insertion sort will need to loop?
An insertion sort will need to run one less times than the list length
What requirements are there to use Binary Search?
Must have a sorted list
What kinds of iteration do other sorting algorithms use?
Bubble Sort can be looping or recursive. Bucket Sort is looping. Quicksort is recursive.
How are algorithms measured based upon efficiency?
Algorithms are expressed based on the maximum number of operations they will need to run. These may be plotted on a graph which visualises how it will scale with larger numbers
What is validation?
It’s a process of ensuring that the product meets the needs and expectations of stakeholders. It tests the usability, functionalities and reliability of the end product. It emphasises executing the code to test the usability and functionality of the end product. It targets the end product that is ready to be deployed
What is verification?
It’s a process of checking if a product is developed as per the specifications. It tests the requirements design of product. It does not require executing the code and it targets internal aspects like requirements