Data Types (36%) Flashcards
A data structure for implementing a list ADT, where each node has data and a pointer to the next node. The list structure typically has pointers to the list’s first node and last node.
Singly linked list
A data structure for implementing a list ADT, where each node has data, a pointer to the next node, and a pointer to the previous node.
Doubly-linked list
A data structure that stores unordered items by mapping (or hashing) each item to a location in an array (or vector). Dictionaries and arrays.
Hash table
Data structure where each node has up to two children, known as a left child and a right child. “Binary” means two, referring to the two children.
Binary tree
A complete binary tree that maintains the simple property that a node’s key is greater than or equal to the node’s children’s keys.
(Actually, a max-heap may be any tree, but is commonly a binary tree).
Max-heap
Is similar to a max-heap, but a node’s key is less than or equal to its children’s keys.
Mini-heap
A common ADT for holding ordered data, also known as a sequence. created by using brackets []. Array and linked list.
List ADT
ADT that stores a collection of data, like a list, but is immutable. Created using () with elements seperated by commas.
Tuple ADT
ADT that has an unordered collection of unique elements. Empty ADT can only be created using (). Binary search tree and hash table.
Set ADT
ADT Python container used to describe associative relationships. Empty created using {}. Elelements are added using key:value pairs. Hash table and binary search tree.
Dictionary ADT
ADT in which items are only inserted on or removed from the top of a stack. (Last in, first out). Linked list or array.
Stack ADT
ADT in which items are inserted at the end and removed from the front. Linked list or array.
Queue ADT
ADT in which items can be inserted and removed at both the front and back. Linked list or array.
Dequeue ADT
ADT where each item has a priority, and items with higher priority are closer to the front than the items with lower priority. Heap
Priority queue ADT
An ADT for holding ordered data and allowing indexed access. Array.
Dynamic array ADT.