Fundamentals of Data Structures Flashcards
1
Q
Define Data Structure
A
Any method used to store data in an organised and accessible format.
2
Q
Define Array
A
A list/table of data, with an associated name used to reference it. Each item is called an ‘element’ and all elements have the same datatype.
3
Q
One Dimensional vs Two Dimensional Arrays
A
- A one dimensional array is used to store a list of data.
- A two dimensional array is used to store a table of data.
4
Q
Limitations of Arrays
A
- They are allocated a fixed size when created, which cannot be changed during runtime.
- They only store elements of the same data type.
- Arrays take up the same amount of memory whether they are full or empty, meaning sparsely populated arrays lead to inefficient memory usage.
5
Q
Define Text File
A
A file that contains human-readable characters.
6
Q
Define Binary File
A
A file that stores data as sequences of 1s and 0s
7
Q
Define Record
A
One line of a text file
8
Q
Define Field
A
An item of data
9
Q
A