## Curiosity 2006

This is an algorithm trace task. No implementation is required.

Read the following algorithm for the recursive function called Curiosity that needs two integers as inputs and returns an integer value.

In the algorithm, MOD is an operator. It works with two integers to give the remainder when the first integer is divided by the second. This means that

- 17 MOD 7 is 3
- 72 MOD 15 is 12

## Press Cutting Service

**This is a software development task and an implementation task.**

A group of Sixth Form students have decided to run a press cutting service for the students in their school. They intend to identify and take cuttings of topics related to each examination subject taught at the school.

They propose to hold basic information about each cutting on a database. Students will be able to access this database.

## Examination Centre

**This is an algorithm trace task. No implementation is required.**

Read the algorithm below, which validates an Examination Centre number and determines whether it is an overseas or a UK Centre.

The function Len(code) returns the number of characters in code. For example, if code = JA3451,

Len(code) = 6.

The algorithm refers to the one dimensional array err, which has been dimensioned to five cells.

Each output starts on a new line.

## Mystery 2008

**This is an algorithm trace task. No implementation is required.**

Read the following algorithm for the recursive procedure called Mystery.

Where

- LEN(aSTRING) returns the number of characters in the string held in aString,
- MID$(aString, n,m) returns m characters of aString starting at the nth,
- LEFT$(aString, n) returns the first n characters of aString,
- RIGHT$(aString, n) returns the last n characters of aString,
- & joins two strings together (concatenation).

## The Dice Game

The dice simulator and subsequent dice playing game was a Pre-2015 GCSE CS Controlled Assessment task from OCR. It is probably their most exciting coursework ever and is here so everyone gets a chance. It also contains hints on completing the CA well.

## Area Calculator

In this challenge you should write a program that calculates the area of different shapes. It is a chance for you to practice basic maths inside a program amongst other skills. I would approach it something like:

- Create a program that will calculate the area of a rectangle.
- Use an IF statement to ask the user which shape they would like to calculate the area of.
- Add an option for a Triangle.
- Import the maths library and use it to calculate the area of a Circle.
- At this point you might think about using methods to split your code up into small manageable chunks.

**Flowchart Description of the Algorithm.**

### Extension

Write a program to calculate the **surface area** of the following shapes: a square, a cube, a pyramid, and a cylinder. Ask the user which shape he would like to calculate the area for, and the dimensions that are needed for the calculation.

The formulæ for each shape follows.

- Area of a cube: 6 X (Length of side)2
- Area of a pyramid: (Number of faces X Length of base X Height) / 2
- Area of cylinder : 2?Radius X Height

## Informatics (01)

### Introduction

The seventh year of the UK Informatics Competition organised by Richard Forster and Antony Rix. The students had to complete a series of challenges including Friends and Playfair. Click here to view all the competition tasks. © British Informatics Olympiad

## Informatics (03)

The ninth year of the UK Informatics Competition organised by Richard Forster and Antony Rix. The students had to complete a series of challenges including ISBN and Virtual Lakes.

## Einee-Meenie-Minee-Mo (04)

A group of friends are standing in a circle playing a game. They proceed around the circle, chanting the rhyme and pointing to the next person (clockwise) on each word. When the rhyme finishes whoever is being pointed at leaves the circles. Then they start again, pointing where they left off, and the game continues until only one person is left.

The version of the rhyme they are using is

Eeny, meeny, miny, moe,

Catch a tiger by the toe.

If he hollers, let him go,

Eeny, meeny, miny, moe.

Write a program, which given the number of friends and the length of the rhyme, can determine who wins.