Python Variables Flashcards

1
Q

Variables are containers for storing data values.

A

Variables

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

Python has no command for declaring a variable.

A

Creating Variables

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

A variable is created the moment you first assign a value to it.

A

Creating Variables

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

Variables do not need to be declared with any particular type, and can even change type after they have been set.

A

Creating Variables

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

If you want to specify the data type of a variable, this can be done with casting.

A

Casting

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

You can get the data type of a variable with the type() function.

A

Get the Type

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

String variables can be declared either by using single or double quotes:

A

Single or Double Quotes?

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

Variable names are case-sensitive.

A

Case-Sensitive

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