data structures Flashcards

1
Q

array

A

an ordered, finite set of elements of a single type

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

record

A

a set of fields of different data types of a fixed size

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

list

A

a data structure consisting of a number of items

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

list vs array

A

lists can store data non-contiguously

lists can store more than one data type

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

tuple

A

an immutable, ordered set of values of any time

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

stack

A

a LIFO abstract data type

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

stacks - uses

A

back button in a web page, undo buttons, memory management for subroutines

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

queue

A

a FIFO abstract data type

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

stacks: push(value)

A

adds a new value to the top of the stack

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

stacks: peek()

A

returns the top value of the stack without removing it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

stacks: pop()

A

returns and removes the value at the top of the stack (end of the list)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

queue: enQueue(value)

A

adds the value to the end of the queue

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

queue: deQueue()

A

removes the item from the end of the queue

How well did you know this?
1
Not at all
2
3
4
5
Perfectly