2.3.1. Algorithms exam questions

2.3.1. Algorithms exam questions

12th Grade

19 Qs

quiz-placeholder

Similar activities

Pre-assessment

Pre-assessment

11th - 12th Grade

20 Qs

1.05 & 1.06 Vocabulary

1.05 & 1.06 Vocabulary

KG - University

21 Qs

CFDA: Unit 2 Pre-Assessment

CFDA: Unit 2 Pre-Assessment

9th Grade - University

15 Qs

Basics of App Coding

Basics of App Coding

8th - 12th Grade

22 Qs

Exploring the Basics of C Programming

Exploring the Basics of C Programming

11th Grade - University

20 Qs

animals

animals

KG - Professional Development

16 Qs

AP Computer Science A Quarterly Exam

AP Computer Science A Quarterly Exam

12th Grade

15 Qs

INFORMATIKA .1

INFORMATIKA .1

12th Grade

20 Qs

2.3.1. Algorithms exam questions

2.3.1. Algorithms exam questions

Assessment

Quiz

Other

12th Grade

Easy

binary search, binary tree, Quick sort

+13

Standards-aligned

Created by

Ian Currie

Used 6+ times

FREE Resource

19 questions

Show all answers

1.

OPEN ENDED QUESTION

3 mins • 2 pts

Media Image

Describe the purpose of this algorithm.(2)

Evaluate responses using AI:

OFF

Answer explanation

Answer:

  • To locate an item (1) in a list (1). The list is in some order (1).

Tags

Algorithms

binary search

2.

OPEN ENDED QUESTION

3 mins • 8 pts

Media Image

Parameters are passed to this function. Complete the following table to identify these parameters and the purpose of each. (8)

Evaluate responses using AI:

OFF

Answer explanation

Answer:

  • A (1 AO – 1.2) the list to be searched (1 – AO 2.1).

  • Value (1 – AO 1.2) the item being searched for (1 – AO 2.1).

  • Low (1 AO – 1.2) the lower end of the list / sublist (1 – AO 2.1).

  • High (1 AO – 1.2) the upper end of the list / sublist (1 – AO 2.1).

Tags

Algorithms

binary search

3.

OPEN ENDED QUESTION

3 mins • 2 pts

Media Image

Describe what is meant by recursion. (2)

Evaluate responses using AI:

OFF

Answer explanation

  • The function calls itself (1) from within the function.

Tags

Algorithms

binary search

4.

OPEN ENDED QUESTION

3 mins • 3 pts

Media Image

Explain how the algorithm in Fig.2 is an example of a divide and conquer approach. (3)

Evaluate responses using AI:

OFF

Answer explanation

  • Answer:

    • Divide and conquer splits a big problem into smaller parts (1). This algorithm repeatedly splits the list (1) in half (1) which reduces the amount of searching (1).

Tags

Algorithms

binary search

divide and conquer

5.

OPEN ENDED QUESTION

3 mins • 8 pts

Media Image

Rewrite the algorithm in Fig.2 without using recursion. Annotate your pseudocode with comments to show how it solves the problem. (8)

Evaluate responses using AI:

OFF

Answer explanation

Media Image
  • Answer: Individual steps in pseudocode:

    • Function declaration

    • Parameters all given correctly

    • Found flag used

    • Mid-point found

    • Check if value found is greater than looked for value

    • Check if value found is less than mid value

    • Mid-point adjusted

    Programming marks to be awarded as follows:

    • Function declaration with parameters all given correctly (1 – AO 3.2)

    • Found flag and midpoint (1 – AO 3.2)

    • Checks if value found is greater or less than looked for value (1 – AO 3.2)

    • Mid-point adjusted within a loop (1 – AO 3.2)

    Possible annotated comments:

    • An If is used to catch an unordered list (1 – AO 2.2).

    • A WHILE loop deals with the logic that tests the binary search conditions without needing to use recursion (1 – AO 2.2) by reiterating through the conditions (1 – AO 2.2).

    • A found flag is used as the exit condition of the loop so that when the number is found the loop ends (1 – AO 2.2).

    Accept other valid annotations.

Tags

Algorithms

binary search

re-writing algorithm

6.

OPEN ENDED QUESTION

3 mins • 4 pts

Media Image

Explain two reasons why they might use the new flight path in the simulation before implementing it in the real world. (4)

Evaluate responses using AI:

OFF

Answer explanation

Answer: 1 mark per bullet
e.g.

  • It is safer… (1)

  • …Real planes / lives are not put at risk by testing it in reality (1)

  • Time can be sped up / decreased … (1)

  • … do not need to wait to see what happens, can view changes immediately (1)

  • It will cost less… (1)

  • …Can make multiple changes / test all possibilities (1)

Tags

performance modelling

7.

OPEN ENDED QUESTION

3 mins • 2 pts

Media Image

The board shown in Fig 2.1 is a visualisation of the problem. Explain what visualisation means in this example. (2)

Evaluate responses using AI:

OFF

Answer explanation

Answer: 2 marks, 1 for defining visualisation, 1 for application to the 2-d array and gridd

  • Presents data in an easy-to-grasp way (1)

  • An array is not actually a grid / table (1)

Tags

Visualisation

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?