Malbolge Medium · Lesson 1 · On the house

Search programs

Malbolge · medium · Search programs. Lesson 1 is free — on the house.

Lessons · Malbolge Medium · Lesson 1 of 10 · On the house

Search programs

Malbolge · medium · Search programs.

Illustration for the Malbolge course
Lesson 1 is on the house. The rest opens with the paper, the Daily, or a gift.

Easy built a tiny generator for one-letter targets. Medium scales into real search programs: structured exploration with faithful simulation, caps, and honest fitness.

A search program proposes candidates, runs them, scores them, and decides what to try next. Random search, hill climbing, beam search, and evolutionary search are family members — pick by budget and exploitable structure.

Faithfulness first: if the embedded interpreter disagrees with your reference on crazy2 or EOF, search optimizes a fiction. Lock a golden vector suite before long runs.

Representation choices: raw printable characters; restricted alphabets; normalized programs that compile downward. Restricted alphabets shrink space; normalization adds bias that helps or hurts.

Operational concerns: step caps, memory, parallel workers, checkpointing elites, deterministic seeds for reruns. A search you cannot reproduce is a story, not a result.

Target design: grow prefix length slowly. Ladder H → He → Hel → … with saved elites as warm starts. Jumping to full Hello without rungs wastes heat.

Pitfalls: unfaithful interpreters; uncapped runs; nonreproducible chaos; vanity targets; ignoring illegal-op rates; celebrating length without correctness.

Deepening medium-search-programs: write precondition and postcondition in one sentence each before you touch search or a tracer. Vague goals produce vague fitness and vague traces. Malbolge amplifies vagueness into wasted CPU.

Workbench on medium-search-programs: change one knob — mutation rate, step cap, table constant, dialect flag — then remeasure. Batch knobs create superstition. Lab notebooks beat lore.

Portability for medium-search-programs: name the interpreter family beside every result screenshot. Classic versus normalized versus experimental ports disagree politely until they ruin your week.

Composition for medium-search-programs: after a success, break it on purpose (wrong EOF, tighter cap, swapped crazy2) and record the symptom line. Symptom catalogs are Expert fuel.

Teach-back for medium-search-programs: explain today's still without looking, using only a/c/d and one dump line. Hesitation is a map of what to restudy.

Numeric drill on medium-search-programs: three micro-targets or three micro-traces beat one theatrical attempt. Medium difficulty cliffs are climbed in switchbacks.

Naming for medium-search-programs: label candidates, elites, and fixtures with roles — seed, mutant, champion, oracle. Stale names in logs lie harder than stale Malbolge cells.

History of practice for medium-search-programs: keep failed fitness curves. A flatline teaches as much as a spike. Your future self will thank the ugly plots.

Negative space for medium-search-programs: list what you will not claim today — no casual hand hello, no universal dialect, no cruelty-as-virtue. Negatives keep judgment clean.

Search is not a single algorithm — it is a contract between proposal distribution and evaluation oracle. If your proposals ignore position-sensitive decode, the oracle mostly returns barren. Shape proposals with legal-decode bias when you can measure it.

Checkpoint elites to disk every N generations with the RNG seed and interpreter commit hash. Future-you will need to reproduce a champion that looked obvious at 2 a.m. and mysterious after coffee.

Partial-credit fitness (prefix length) is kinder than binary success and still honest. A population climbing from 0→1→2 characters is learning; a population stuck at 0 with rising generation counts is not.

When workers disagree on a candidate's score, you have nondeterminism or a race — stop the cluster and fix seeds before trusting any trophy.

Proposal distributions that ignore decode legality burn evals. Measure illegal rates per generation and treat spikes as bugs in the proposer, not bad luck.

Warm-start from shorter-ladder elites when extending the target by one character. Cold starts at each rung waste the curriculum of the previous rung.

Log not only best fitness but also the histogram of prefix lengths. A rising mean with a stuck max hints at diversity without breakthrough.

Assessment angle on search programs: predict one dump field before revealing the tracer line. Wrong predictions are tuition — write them down.

Refactor note on search programs: after it works, rename log fields and tighten the lab report section for this idea so next week's you can reuse it.

Edge cases for search programs: try the empty program, a one-glyph program, and a max-length-under-budget candidate. Edges expose loader and fitness lies.

Caller contract for search programs: document what your tool clobbers — RNG state, working files, interpreter globals — like an ABI between lab scripts.

(Lesson 1 deepen.) Return to the still after each quiz miss and point to the sentence that already answered it. Open-book means the page is a tool, not a trap.

Change one mental model at a time: radix, then tables, then encrypt, then search. Stacking model changes manufactures superstition.

Keep a running glossary in your notebook — trit, crazy, crazy2, a, c, d, normalize, fitness, dialect. Definitions drift if unwritten.

When stuck, shrink the experiment until one cycle is understandable. Magnification beats marathon confusion.

search-program

# Malbolge · Search programs
# Level: medium
Search programs note

Walked still — Search programs note: type it exactly. Matching Host notes trains the same precision you need when candidates differ by one glyph.

Quiz

A search program mainly?

Quiz

Before long runs you should lock?

Quiz

Growing targets by prefix ladders helps because?

Quiz

Nonreproducible search is?

Quiz

Restricted alphabets?

Quiz

Unfaithful crazy2 in the loop causes?

Check

Match the still for: Search programs.

Check

Type the Host note still for this lesson.

Search framed. Next: genetic approaches.

Open-book: the answers are on this page. Pass every quiz and check (8) to mark the lesson done. This visit: 0/8.

Search programs · Malbolge Medium (free) — The Gold Standard