Python quiz question

I gave the following code to my Year 12 class and asked them what it would output (multichoice):

  1. age = 14;
  2. driversage=16;
  3. print (“You are:”, age, “the drivers age is:”, driverage, “Sorry you have”, driversage-age, “years to go”)

They had to choose from:

a.Nothing
b.You are: 14 the drivers age is: 16 Sorry you have 2 years to go
c.Error message
d.You are 14 the drivers age is 16, Sorry you have 2 years to go

Only 18% got the correct answer – which is what I expected. Students have to look carefully to get the correct answer.

I will post the answer later.

Advertisements
This entry was posted in Uncategorized and tagged . Bookmark the permalink.

2 Responses to Python quiz question

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s