Ex. 37 Data Types Flashcards

1
Q

true

A

True boolean value.

true or false == true

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

false

A

False boolean value.

false and true == false

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

nil

A

Represents “nothing” or “no value”.

x = nil

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

strings

A

Stores textual information.

x = “hello”

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

numbers

A

Stores integers

i = 100

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

floats

A

Stores decimals.

i = 10.389

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

arrays

A

Stores a list of things.

j = [1,2,3,4]

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

hashes

A

Stores a key=value mapping of things.

e = {‘x’ => 1, ‘y’ => 2}

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