practice test questions Flashcards
What is decomposition?
The breaking down of a problem into smaller, simpler steps or stages.
Which is easier to write or code ?
a linear search
A Syntax error is?
An error caused by misspelling code, or using the wrong keywords
What can searching algorithms be used for?
Software applications
Which of the below describes the way a bubble sort algorithm works?
Step through the list comparing current and next values and swapping if necessary
When decomposing a problem what kind of structure can we use?
A structure diagram
Which search algorithm is more efficient?
binary search
What is abstraction?
The removal of unnecessary details
A logic error is..?
An error in a program which is unintentionally incorrect, but the program works
Which search algorithm is good for a list with not many items?
Linear search
What is the point in using a flowchart?
It gives a clear flow on the way the code should work and gives a vague outline
Why do we use pseudocode when coding?
It is used in planning an algorithm when sketching out the structure of the program
before actually coding
What happens in stage 2 of the merge sort?
Each pair of sublists is repeatedly merged to produce new sorted sublists
How does binary search work?
It repeatedly divides portion of list in half
What is an algorithm?
A series of instructions to complete a task