DS Basics Flashcards
A __________________ is a way to store and organize data to facilitate access and modifications
Data Structure
Gives us the algorithms to support operations
Data Structure
Two Main DS Approaches
Arrays and Linked lists
is a collection of same data type elements stored at contiguous
memory locations
Array
An array is a collection of same data type elements stored at __________ memory locations
contiguous
How array is represented in memory
array[i] = memory[address(array) + i]
Characteristics of Array
easy to implement
fast random access
fixed size
A collection of dynamic variables linked together to form a chain-like structure
Linked Lists
A linked list is collection of ___________ variables linked together to form a _____________ structure
dynamic, chain-like
Characteristics of Linked Lists
more complex
sequential access
dynamic size
A mathematical model, together with various operations defined in the model
Abstract Data Types (ADTs)
A sequence of elements of the same type
List ADT