1/129
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai | Chat |
|---|
No analytics yet
Send a link to your students to track their progress

E

B



D

AC



ABC

ABCD

CD

BC

C

A

B

what is the output
True
True

BD

what is the output


what is the output


ABD

ACEFG

D

What was the type of error that was printed? The text for this should be shown in IDLE, toward the end of the red text.
A) ZeroDivisionError
B) TypeError
C) NameError
D) ValueError
E) IndexError
C

Based on what was printed by the fifth line, what do you think the ** operator does?
F

Answer Question 1
1

Answer Question 2
B

ACD

B

E

the variable b is what?
an integer

the variable c is what?
a decimal number

the variable d is what?
Boolean



Q1
D

Q2
C

c is what?
boolean

A

Q1
A

Q2
B

Q3
C

Q4
B

Q5
A



C

what is the name of the first error?
syntax error on line 3

in reality, the computer will stop when it hits that first error and won’t try to run any more code, however, imagine that it skipped the line (in this case line three) that causes the first error. on what line will it encounter a second error?
line 6

what type of error is line 6 called?
NameError

does this result in an error? If so, what type
SyntaxError



ABCEF



Q1
Helloworld

Q2
None



BCDE



Q1
ABC

Q2
BC

Q3
C



convert the first into an int, the second to a float, the third to a boolean


Q1
B

Q2
A; reserved word ‘continue’ is used

A; the coder used the function as variable name which is usually fine if you don’t actually use the function, but they did in line 4

will this generate an error?
yes, they used a function as a variable



write some code that will print this output

Q1
AE

Q2
BF

CD

C

E; remember it’s not ==

B



False
True
False
False
True



ABEFG

B





AE

ABE

BC

CDE

CDE

AE

ABD

AD

ACD

AB

BCD



DEHKL

ABCFG

Q1
A

Q2
D

print(a + b * c)
15

print((a b) / (2 a))
2.0

print(a / (b - 2 * c))
An error message

Q1
0

Q3
1

Q2
3