// coding puzzle aesthetic · compile locally

Reorder opcodes.
Satisfy the assert.

World of Code is a browser puzzle dressed like a midnight IDE: drag instruction tiles, watch the virtual machine glow, and chase a clean compile streak.

Features that feel like tools

Tiny VM

PUSH, ADD, MUL, DUP, PRINT, SWAP — enough ops to teach stack thinking without a textbook.

Live asserts

Each level states a glowing condition. Run to see pass/fail with a readable trace.

Streak storage

Successful compiles increment a local streak. Break the assert? Streak resets, ego survives.

Sandbox — Stack Garden

Drag opcodes into the program strip (or click to append). Hit Run. Satisfy the assert to level up.

Available opcodes (click to append)
Program (click a chip to remove)
Level 1 · Streak 0

  

Commit log — Why the garden compiles

In the year the satellites forgot their names, a caretaker process kept a rooftop garden of glowing stacks. Visitors were not asked for résumés—only whether they could make out == "OK" without overflowing the soil (the stack).

World of Code is that garden, shrunk into a tab. You are not applying for a job. You are learning the poetry of order: what must be pushed before it can be added, what must be duplicated before it can be printed twice.

Every green assert is a small harvest. Failures are compost.

How to play (quick docs)

1. Read the assert

It tells you the required output string and sometimes a peak stack size.

2. Build a program

Click opcodes from the palette. Click chips in the program strip to remove them.

3. Run & iterate

Trace lines show stack state after each op. Fix, re-run, advance.

Opcode reference

PUSH n — push literal. ADD/MUL — pop two, push result. DUP — duplicate top. SWAP — swap top two. PRINT — pop and append to output.

Debug tips

FAQ

Do I need to know a real language?

No. The VM is fictional and tiny. Stack intuition helps in real languages later, but the demo stands alone.

Is this competitive programming?

Absolutely not. It is an aesthetic puzzle with educational side effects.

Can I save programs?

Streak and level index store locally. Programs are ephemeral—screenshot if you love a solution.

Sponsor

www.mainbrain.fun funds curious browser experiments like this.