Difference between revisions of "2022 Paper 1 Revision Quiz"
(→Queues) |
|||
Line 266: | Line 266: | ||
</tr> | </tr> | ||
<tr> | <tr> | ||
− | <td>C</td><td>{ None }</td> | + | <td>C</td><td>{ None (i) }</td> |
</tr> | </tr> | ||
<tr> | <tr> | ||
− | <td>D</td><td>{ None } </td> | + | <td>D</td><td>{ None (i) } </td> |
</tr> | </tr> | ||
</table> | </table> | ||
Line 430: | Line 430: | ||
|type="{}"} | |type="{}"} | ||
− | 1) Constant : { O(1) } | + | 1) Constant : { O(1) (i) } |
− | 2) { Logarithmic } : O(log N) | + | 2) { Logarithmic (i)} : O(log N) |
− | 3) Linear : { O(N) } | + | 3) Linear : { O(N) (i) } |
− | 4) Linearithmic : { O(N log N) } | + | 4) Linearithmic : { O(N log N) (i) } |
− | 5) { Polynomial } : O (N<sup>2</sup>) | + | 5) { Polynomial (i) } : O (N<sup>2</sup>) |
− | 6) { Exponential } : O(k<sup>N</sup>) | + | 6) { Exponential (i) } : O(k<sup>N</sup>) |
− | 7) Factorial : { O(N!) } | + | 7) Factorial : { O(N!) (i) } |
{Complete the Order of Complexity for the following examples: | {Complete the Order of Complexity for the following examples: | ||
|type="{}"} | |type="{}"} | ||
− | 1) Finding the first item in a list : { O(1)|Constant } | + | 1) Finding the first item in a list : { O(1)|Constant (i) } |
− | 2) { Binary Search } : Logarithmic or O(log N) | + | 2) { Binary Search (i) } : Logarithmic or O(log N) |
− | 3) { Linear Search } : Linear or O(N) | + | 3) { Linear Search (i) } : Linear or O(N) |
− | 4) Merge Sort : { Linearithmic|O(N log N) } | + | 4) Merge Sort : { Linearithmic|O(N log N) (i) } |
− | 5) { Bubble Sort } : Polynomial or O (N<sup>2</sup>) | + | 5) { Bubble Sort (i) } : Polynomial or O (N<sup>2</sup>) |
− | 6) { Chess Board Problem } : Exponential or O(k<sup>N</sup>) | + | 6) { Chess Board Problem (i) } : Exponential or O(k<sup>N</sup>) |
− | 7) { Travelling Salesman Problem }: Factorial or O(N!) | + | 7) { Travelling Salesman Problem (i) }: Factorial or O(N!) |
</quiz> | </quiz> | ||
Line 454: | Line 454: | ||
{Complete the Halting Problem: | {Complete the Halting Problem: | ||
|type="{}"} | |type="{}"} | ||
− | ‘Is it possible to { write|create } a program that can tell given any { program } and its { inputs } and without { executing } the program, whether it will { halt }?’ | + | ‘Is it possible to { write|create (i) } a program that can tell given any { program (i) } and its { inputs (i) } and without { executing (i) } the program, whether it will { halt (i) }?’ |
</quiz> | </quiz> |
Revision as of 10:10, 3 June 2022
Contents
Recursion
Arrays
Abstract Data Types & Dynamic vs Static
Queues
Stacks
Graphs
Trees
Graph Traversal
Searching Algorithms
Sorting Algorithms
Optimisation Algorithms
Order of Complexity