4 – Quiz Project

🎯 Learning Objectives

Develop the Programming & Development, Algorithms Learning Strands:

  • Create a simple user interface.
  • Use the button inputs to control the program.
  • Understand what a variable is, how to name it and use one in a program.
  • Use simple maths operators in a program.
  • Learn how to generate random numbers within a range.
  • Learn how to test a program.
💬 Key Vocabulary

  • Success criteria
  • Multiplication
  • Integer
  • User interface
  • Variable
  • Random
  • LED
  • String

📝 Starter Activity – LEDs

  • The screen on the micro:bit is made of LEDs.
  • LED stands for light emitting diode.
  • When you pass electricity through an LED it lights up.
  • The more electricity you pass through it the brighter it will be.
  • To dim the LED you reduce the amount of electricity passing through it.
  • You can control the brightness on an LED on the micro:bit.
  • The code below sets the brightness to 255 when Button A button is pressed – this is the maximum brightness for the LED on the microbit.
  • To represent 255, 8 bits are required in binary.
  • In computer science we call 8 bits a byte.
  • When Button B is pressed the LED is set to 5 which isn’t very bright.
  • You should write this program on your micro:bit. Can you add additional blocks of code so that is acts as a dimmer switch?

📖 Project Based Learning

  • Project based learning will allow you to explore new concepts through practical activities.
  • These are larger projects than the practical tasks which require you to plan and develop a solution.
  • Some projects will be completed in pairs although this initial one will be completed individually.
  • When you are given the project you will start by identifying what your solution will need to do.
  • You will use success criteria to do this.

📖 Success Criteria

  • Success criteria should be identified before starting to produce the solution.
  • The success criteria will state what the product should do once it has been created.
  • Initially you should read the task and then split it up into a number of criteria that you can measure.
  • At the end of the project, you will evaluate your product against the success criteria that you have identified.

📖 Maths Quiz

  • Over the lesson you are going to create a maths quiz which can be played on the micro:bit
  • What success criteria should we define for our maths quiz?
  • Write down 3 success criteria in a blank word document.

📖 Variables

  • Variables are like empty boxes which allow us to temporarily store data in
  • In a computer system they are named locations in memory which allow computers to store data
  • If we wanted to store your first name we could take a box and name it ‘firstName’. You could then store your first name in that box.
  • In a maths quiz, what variables do you think will need to be used?
  • Write down 3 possible variables you could use in your program, add them to your word document.

📖 Gold/Platinum – Maths Quiz

  • Your task is to produce a maths quiz on the micro:bit.
  • You will work through the tutorials to create the actual maths quiz.
  • Download the worksheet below to see how to create the quiz:

In this lesson, you…

  • Created a maths quiz.
  • Use LEDs to create output.

Next lesson, you will…

🏅 Badge it

🥈 Silver Badge

🥇 Gold Badge

🥉 Platinum Badge