Hello, dear friend, you can consult us at any time if you have any questions, add WeChat: daixieit

COMP3506/7505 Project

Due: 23rd September 2022

Report Template

1. Overview

This document is the mandatory template which must be used to submit the report section of your project.

This template is automatically synced with Gradescope to identify the location of each section of the report; therefore, it is imperative that the overall format/layout of this document not be modified. Modification of the template will result in a penalty being applied.

You are permitted to make changes inside the purple boxes for each question provided however the overall size of the box cannot change. Your report should easily fit within the boxes provided however please be aware the minimum font size allowed is Arial 10pt. If you are exceeding the box size, then this may be a good indication your response is not succinct.

2. Submission

Once you have completed your report this document must be exported as a pdf and uploaded to the Gradescope Report Portal for Part B of this assignment. This document should not be uploaded to the autograder.

3. Marking

The report will be hand marked by the teaching team. Information regarding the rubrics used while marking will be made available after grades are released. While this report will indicate the relative weighting of each section of the report, should there be any discrepancy with the official assignment specification, the assignment specification shall take precedent.

4. Plagiarism

The University has strict policies regarding plagiarism. Penalties for engaging in unacceptable behaviour can range from cash fines or loss of grades in a course, through to expulsion from UQ. You are required to read and understand the policies on academic integrity and plagiarism in the course profile (Section 6.1).

If you have any questions regarding acceptable level of collaboration with your peers, please see either the lecturer or your tutor for guidance. Remember that ignorance is not a defence!

5. Task

You are required to complete all sections of this report in line with the programming tasks completed in the project.

Hospital Appointment System (16 Marks)

Hospital 1

1.  State the data structure used to store patients and explain why this data structure is the

best for the task in hand.


2.  Describe the algorithm used to order the patients. Briefly explain how it works, from

where it is called (from iterator/__iter__ or from addPatient/add_patient) and why it is the best algorithm in comparison with the other known algorithms.


3.   Assuming n to be the number of patients, state the best-case (Ω) and worst-case (O) time complexity of iterator/__iter__ and addPatient/add_patient with respect to n.


Hospital 2

1.  State the data structure used to store patients and explain why this data structure is the

best for the task in hand.


2.  Describe the algorithm used to order the patients. Briefly explain how it works, from

where it is called (from iterator/__iter__ or from addPatient/add_patient) and why it is the best algorithm in comparison with the other known algorithms.


3.   Assuming n to be the number of patients, state the best-case (Ω) and worst-case (O) time complexity of iterator/__iter__ and addPatient/add_patient with respect to n.


Hospital 3

1.  State the data structure used to store patients and explain why this data structure is the

best for the task in hand.


2.  Describe the algorithm used to order the patients. Briefly explain how it works, from

where it is called (from iterator/__iter__ or from addPatient/add_patient) and why it is the best algorithm in comparison with the other known algorithms.


3.   Assuming n to be the number of patients, state the best-case (Ω) and worst-case (O) time complexity of iterator/__iter__ and addPatient/add_patient with respect to n.


Login System (14 Marks)

1.  What is the advantage of storing a hash code of the password instead of the plain text password?


2.  Do we need to store the email in the hash table? If your answer is yes, explain why it is

necessary. If your answer is no, explain how you use the email (if you use it at all) .


3.  Which of the following is an example of a collision? Explain your answer for both cases .

(a) Two users have the same email hash

(b) Two users have the same password hash


4.  What is the type of hash code function being used? Explain why it is suitable for use in

this hash table.


Tree of Symptoms (10 Marks)

1.  What is the type of the restructured tree?

 

2.  For any given binary tree, is the reconstructed tree balanced? If so, explain why. If not,

give a counter-example.


3.  For any given binary tree, is the reconstructed tree unique? If so, explain why. If not,

give a counter-example.