CT and Programming 4 Flashcards
1
Q
What is a
data structure?
A
an organised collection of related elements
(e.g. list, array)
2
Q
What is a
one-dimensional data structure?
A
a data structure where the elements are arranged in one direction
(e.g. list, string)
3
Q
What is the difference between
arrays and records?
A
an array is a data structure containing only one data type
a record is a data structure storing multiple different data types
4
Q
What are the similarities and differences of iteration and repetition?
A
+both repeat a section of an algorithm
-iteration repeats for every item in a data structure
-repetition repeats either a fixed number of times or until a condition is met
5
Q
What is a
two-dimensional array?
A
an ‘array of arrays’