Tag: Selection

Resistor in Series and Parallel

resistors-formulae

In this blog post we will create a Python program that will help us calculate the total resistance when two resistors are connected either in series or in parallel. This program will be based on the following formulae: Program Flowchart

Hogwarts Sorting Hat Challenge

hogwarts-sorting-hat

In the Harry Potter series of novels written by British author J. K. Rowling, The Sorting Hat is a magical hat at Hogwarts that determines which of the four school Houses each new student belongs most to. These four Houses

Voting Age Checker – Flowchart

flowchart-voting-age-checker

For this challenge you are going to code a script to ask a user how old they are and inform them as to whether they are old enough to vote or not. If they are not old enough to vote,

Archery Scoring Algorithm

archery

In this challenge we will write a Python program to randomly shoot an arrow on a target. We will then use Pythagoras’ Theorem to calculate the distance between the arrow impact and the centre of the target. This distance will

The Zoo Keeper’s Puzzles

zoo-penguins

Learning Objectives: This set of puzzles will improve your Python skills when using If Statements (Selection) You will focus on: Using comparison operators: ==, !=, < , >, = Using Boolean Operators: AND, OR, NOT if statements use comparison operators

Coding Puzzles

code-puzzle-start

Complete the following coding puzzles by drag and dropping the lines of codes in the correct order to recreate basic computer programs. Click on the picture below to access the coding puzzles:

Sequencing, Selection & Iteration

class-register

When you write lines of code, there are three ways you can control the order these lines will be executed by the computer: Sequencing: This means that the computer will run your code in order, one line at a time

Guess the country

globe

For this challenge we are going to create a game where the user plays against the computer. The aim of this game is to guess the name of a country. The computer will give the player clues to help them

Haunted House

haunted-house

You are going to write a Python game where the user walks within the different rooms of a haunted house. In each room, something will happen. You will decide what happens when the user enters a room. You can use

Yes or No!

yes-no

Learning Objectives When your computer prorgam is asking questions to the end-user, the end-user may not answer these questions the way you expected them to. This may cause your program to not work properly. Ideally a good program should use