> ## Content Index
> Fetch the complete content index at: https://www.workroom-productions.com/llms.txt
> Use this file to discover other available public pages before exploring further.

# Exercise: Three Things
- URL: https://www.workroom-productions.com/three-things/
- Published: 2025-04-17T12:46:25.000Z
- Updated: 2025-04-23T21:37:37.000Z
- Description: Explore the differences between several things which pass the same tests.
- Author: James Lyndsay
- Tags: Exercises, Exploration

*To be used as a 20 minute exercise in* [*Workroom PlayTime 013*](https://www.workroom-productions.com/playtime-013-three-things/)

I built the same thing three times.

> The small system, written as a web page, takes input in the form of an `inputValue` and a `unit`, and a `scale` to contextualise the number and the unit, and converts that number to a `textOutput` expressing that number as something else in the scale, typically of the right size to be comprehensible. Typical scales are time and distance.

Starting with the same tests, (mostly) the same instructions, and the same names for the target files, I asked an LLM to iterate until the code it put into the files passed the tests.

Here they are, each with their tests. They all take the same [configuration](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/A/src/config/config.json), which sets out the units the things work with.

- [Version C](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/C/index.html), [instructions](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/C/rules.md) and [tests](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/C/test/alltests.html).
- [Version D](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/D/index.html), [instructions](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/D/rules.md) and [tests](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/D/test/alltests.html).
- [Version E](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/E/index.html), [instructions](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/E/rules.md) and [tests](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/E/test/alltests.html).

#### Starting at C??

- [Version A](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/A/index.html), [instructions](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/A/rules.md) and [tests](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/A/test/alltests.html).
- [Version B](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/B/index.html), [instructions](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/B/rules.md) and [tests](https://exercises.workroomprds.com/comparing%5Fgenerated%5Fcode/B/test/alltests.html).

I'd have sworn all the tests passed, but A and B show failures in the HTML handler. So now you have D and E.

## Exercise 1

*10 minutes, microphones on*

Pick one. Explore it. Whatever way you like – knowing that they have the same configuration and pass the same tests, but have different code and may hav differing behaviours.

What looks wrong? Share.

## Exercise 2

*5 minutes, mics on*

Pick another. Explore it, starting with what you saw that was 'wrong' in Ex 1.

Differently wrong? What else looks wrong?

Share.

## Review

*5 minutes, shared notes in Miro*

Write down one novel way you'd try if you came across this situation at work.

Write down one artefact you wanted to use.

Share any conclusions about testing these things which pass the tests

---

## Extension

- Assess the tests
- Look at the instructions
- Write automation to see differences between C, D and E
- Use `diff` or similar to see differences between the underlying code
- Try it yourself! Get the test files into a directory. Ask your LLM of choice to make code to pass the tests in `test-whatever.js`, then give it feedback based on `show-test-whatever.html` . Give it `rules.md`, too – and whatever source you might imagine. You'll need to make (JavaScript) `main`, `htmlhandler`, `relativeSizes`, HTML page `index`. You'll ask for CSS `styles` if you like (there's no test, but you'll want the LLM to have read the rules, the index page and the htmlhandler. You can either use the units from here, or ask for a JSON `config` file to suit yourself (there's a test for that). Certainly change the rules, the tests and whatever else.