5 Modules Flashcards

1
Q

Module

A

A file containing definitions and statements

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

A file containing definitions and statements

A

Module

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

How say turtle.Turtle()

A

In the module turtle, access python element Turtle

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

Print pi

A

print(math.pi)

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

Print square root of 2

A

print(math.sqrt(2))

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

Print sin of 90 degrees

A

print(math.sin(math.radians(90)))

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

Print probability

A

print(random.random())

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

Print random integer between 1 and 6

A

print(random.randrange(1, 7))

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

[ ?

A

Closed interval, inclusive

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

( ?

A

Open interval, non-inclusive

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

Open interval, non-inclusive

A

)

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

Closed interval, inclusive

A

]

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