UNIVERSITY OF TASMANIA
EXAMINATIONS FOR DEGREES AND DIPLOMAS
June 2020
KIT205 Data Structures and Algorithms
PRACTICE EXAM
Examiners: Robert Ollington
Time Allowed: TWO (2) hours
Reading Time: FIFTEEN (15) minutes
Instructions:
There is a total of 120 marks available, and there are TWO (2) sections in this examination.
Section A (60 marks) contains TWENTY FOUR (24) questions.
Section B (60 marks) contains THREE (3) questions.
You must complete all questions in all sections – there are no optional questions.
Section A – Algorithms
This section is worth 60 marks. Complete all questions in this section.
All algorithms must be applied according to detail provided in the unit lectures.
Question 1 (2 points)
Write a simple and tight expression for the worst case big O running time of the following code snippet in terms of the input size, n.
for (i=0; i
for (i=0; i