GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Docs
  • Intro
  • Birthday Algorithm

This view

  • Original page
  • New address

GeezerVison is showing arcade.makecode.com — Activity: Birthday Algorithm

Skip to main content
About
Programming Language For Teachers Authors
Intro
Makecode Orientation Birthday Algorithm Sprites Unplugged: Rock Paper Scissors Variable Math Info Variables
Sprites
Unplugged: Sink a Ship Coordinate Walker Collage Hello Sprite Characters and Stories
Motion
Unplugged: Using a Controller Sprite Motion Event Overlap Section 1 Random Overlap Section 2 On Created Motion Project
Loops
Intro Unplugged: Circle a Chair Increment Loop Projectiles Projectiles from Sprites Physics Loops Project
Unit 1 Review
Extend "touch the button" Paparazzi Asteroid Blaster Baseball Catching Dodgey Duck
Unit 1 Project

Activity: Birthday Algorithm

This activity requires only pencil and paper (no need for a computer). In this lesson students follow a series of steps to complete a math trick.

Students are introduced to:

  • Algorithms
  • Program flow
  • Debugging

Algorithm

An Algorithm is series of steps, decisions and / or formulas. Some common examples include:

  • Cooking recipes
  • Map directions to an address
  • Assembly instructions

Birthday Algorithm

The Birthday Algorithm displays a birthday as month.day after following a set of calculations.

Result is in the format month.day example: March 1st would be 3.01

Link to Video

Follow the Birthday Algorithm steps below working with a partner. Record the steps and the answer for each step so you can troubleshoot. Doing this with just paper and pencil adds to the challenge. If the trick doesn't work, retrace the steps and check each calculation with partner.

Produce a total at the end of each step and use the total in the next step until producing the birthday month.day.

  1. Start with the number 7
  2. Multiply by month the person was born (number 1-12)
  3. Subtract 1
  4. Multiply by 13
  5. Add 5
  6. Subtract 2
  7. Add the day the person was born (number 1-31)
  8. Multiply by 11
  9. Subtract day the person was born (number 1-31)
  10. Subtract month the person was born (number 1-12)
  11. Divide by 5
  12. Add 22
  13. Divide by 200
  14. If not a match of the month.day of the persons birthday, carefully re-read the instructions and check answers at each step

What did we learn?

  1. Describe how well the algorithm worked. Explain what made the algorithm work or what was tried when it did not work.
  2. Explain how the algorithm could be improved in terms of efficiency and usability for the participant. Be sure to describe how to reduce the number of steps while maintaining the trick.
  3. Challenge: Write full equation at each step. Then try to simplify each answer.

Example: first 4 steps

  1. 7
  2. 7m   (m = month)
  3. 7m - 1
  4. (7m - 1)13 = 91m - 13

Teacher Material

Edit this page on GitHub
Edit template of this page on GitHub

You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.