Age for School

This quiz includes Boolean AND, Inputting a variable, Int(), Str() and If..elif..else commands.

Welcome


 

Results

Self Review

Well done. Have a look at any answers you got wrong and look at the feedback.


Investigate Further

Follow this link to the code and run it.

https://repl.it/@PythonSch/SchoolYear

  1. Try out different numbers to get different outputs.
  2. Change the code to make it work differently e.g change the criteria, age ranges etc.

Key Question…

Can you add more options for printing out different sentences? How?

What practical uses might there be for this type of code?

Ask for help

You have made a few errors. In order to ensure you understand everything, have a look at any answers you got wrong and look at the feedback. Ask a partner or adult to help you.


Investigate Further

Follow this link to the code and run it.

https://repl.it/@PythonSch/SchoolYear

  1. Try out different numbers to get different outputs.
  2. Change the code to make it work differently e.g change the criteria, age ranges etc.

Key Question…

Can you add more options for printing out different sentences? How?

What practical uses might there be for this type of code?

#1. Which sentence best describes what the program is designed to do?

Look at what it asks you and what the output is.

  • Does it print as an output which school year you are in?
  • Does it say you are not old enough to be in school?

#2. What is the name of the variable which stores the number you type in?

#3. What do you think the int() and str() commands do?

#4. What will happen if you put in the number 11

#5. Which of these options will make it print that you are “either a teacher or should not be in school.”

  • 5 will say you should be in primary school
  • 17 will say you should be in secondary school
Previous
Finish