



































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




































Qualification BTEC Level 5 HND Diploma in Computing Unit number and title Unit 19 : Data Structures and Algorithms Submission date Date Received 1st submission Re-submission Date Date Received 2nd submission Student Name Phan Anh Ly Ly Student ID GCD Class GCD0905 Assessor name Pham Thanh Son Student declaration I certify that the assignment submission is entirely my own work and I fully understand the consequences of plagiarism. I understand that making a false declaration is a form of malpractice. Student’s signature LyLy Grading grid P1 P2 P3 M1 M2 M3 D1 D
Grade: Assessor Signature: Date: Internal Verifier’s Comments: IV Signature:
II. LO1 Examine abstract data types, concrete data structures and algorithms A. P1 Create a design specification for data structures explaining the valid operations that can be carried out on the structures.
Abstract Data Type (ADT) is a data type whose behavior is determined by a set of values and a set of operations. The abstract data type refers only to what operations will be performed, not how these operations will be performed. It does not specify how the data will be organized in memory and what algorithms will be used to perform the math operations. It is called "abstract" because it hides the details of how the operations are performed but only tells what the operation does is called abstraction. Figure 1 : Abstract Data Type (ADT). Now we’ll define three ADTs namely List ADT , Stack ADT , Queue ADT.
The data is generally stored in key sequence in a list which has a head structure consisting of count, pointers and address of compare function needed to compare the data in the list.
Figure 2 : List ADT. The data node contains the pointer to a data structure and a self-referential pointer which points to the next node in the list. The List ADT Functions is given below: A list contains elements of the same type arranged in sequential order and following operations can be performed on the list.
Figure 6 : Array List removeAt().
Figure 9 : Array List isEmpty().
Figure 14 : Stack ADT pop().
Figure 18 : Stack ADT isFull().
Figure 29 : Array isEmpty(). Figure 30 : Array set().
Figure 31 : Array size(). Figure 32 : Array get().