Module 2 Flashcards

1
Q

Tuples and Lists (Compound data types)

A

.

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

Tuples

A
  • Tuples are an ordered sequence
  • Tuples are expressed as comma-separated elements within parentheses.
  • Are immutable :( (cannot be changed)
  • Tuples use parentheses
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Nesting

A
  • A tuple can contain other tuples as well as other complex data types.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Lists

A
  • Lists are also an ordered sequence.
  • Lists use square brackets
  • Are mutable!
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Aliasing

A
  • Multiple names referring to the same object is known as aliasing
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Clone

A
  • your_variable = previous_variable[:]
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly