The Foundry · Level 3

Make a Tiny Game

Every game is rules, input, and a response. You set the rules. Your guess is the input. The page replies. Put them together and you have a real game.

What is a game made of?

Not magic. Just three plain pieces, all written in code.

Rules What is allowed and how you win. You will set these in a second.
Input What the player does. Here, that is the number you guess.
Response What the game says back. Higher, lower, or you won.
A game is rules plus input plus response. The page will hide a secret number. Your job is to find it. After each guess it answers higher or lower, and counts your tries. All of that is just code following a rule you can read.

← The Foundry · This is a real game, built from rules, input, and a response. The next one is yours: dream it up in Mission Control.