Lesson 7 Flashcards

1
Q

Variables purpose?

A

To store information multiple times throughout a program.

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

4 basic types of data used in python

A

strings
integers
lists
Boolean values

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

Lists

A

ordered sequence of values

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

Strings

A

Represent text

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

Boolean values

A

Represent true or false

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

Identifier is the name of the vairable

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

Don’t include spaces or symbols in identifiers

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

Naming convention

A

A format for naming things like variables

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

Pascal case for naming conventions

A

JollyRoger, NoWay

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

Camel Case for naming conventions

A

heyOh, forReal, buriedTreasure

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

Strings?

A

A group of sequenced characters within either single or double quotation marks.

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

Assign a variable a string value?

A

Just use the operator the equal sign. When text is in quotation marks python recognizes it as a string and not a variable

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

Three single quotation marks ( ‘’’ )

A

It allows you to enter text the exact way you want it to appear

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

You can reuse variable names

A

Just assign the variable a new value and it will overwrite the original value.

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

Escape character

A

Tells python to treat that character as a part of the string instead of a special character. "tornado" would fix the issue.

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

line break

A

\n

17
Q

operators

A

Are symbols that represent actions that manipulate values. Many of the operators we have come from math and they can be used on string or integers.