Lesson 2 of 4 · 60 min

Leave a decision trail in the work sample

Write a concise decision record that a reviewer can challenge.

A work sample shows more than whether code runs. It shows how you chose scope, handled uncertain inputs, and used limited time. Keep a short decision trail while working. This can be a small note with the question, constraint, chosen option, rejected alternative, and verification. The note should explain the final artifact rather than narrate every action.
A useful decision record contains an observable consequence. Choosing local storage because the sample is single-user and must run offline is a meaningful trade-off. Choosing it because it is simple says less unless you explain what work it removes and which guarantee it lacks. The reviewer should be able to change one assumption and ask whether your choice still holds.
Do not manufacture certainty. Estimates should state their basis. A dataset with ten records does not establish production throughput. A fake provider does not establish network recovery. A strong candidate can use both in a time-limited sample while describing the boundaries honestly and identifying the next check.
Make one complete feature work early. Then use the remaining time to improve the largest visible risk. If the data contains conflicting identifiers, spend time on that policy before adding another chart. If the workflow cannot recover from an input error, add recovery before optional animation. This demonstrates ownership of the user's result.

Worked example

A fictional four-hour assignment asks for a tool that summarizes incident tickets. The candidate selects one decision: show the oldest unresolved queue from a local fixture. The record says input is a CSV with stable ticket IDs, missing ages remain unknown, duplicate IDs with conflicting values are rejected for review, and closed tickets are excluded.
The selected design uses a single application and local fixture because the assignment requires no shared persistence. The rejected option is a hosted database, which would consume setup time without improving the required result. The verification uses a five-row hand-calculated fixture and an all-invalid fixture. The known limit is that multiple users cannot save shared edits.

Make the record falsifiable

A decision note should say what assumption makes the choice fit. The local fixture choice is defensible because the assignment does not require shared persistence or real integration. If that assumption changes, the note should point toward a new boundary rather than defend local state forever.
code
1Decision: local CSV adapter for this four-hour sample2Required outcome: correct unresolved-queue summary3Assumptions: one user; supplied fixture; no shared edits4Alternative: hosted database with account setup5Why rejected now: setup adds no required capability6Verified: five-row expected result and all-invalid response7Unverified: concurrent edits, remote permissions, large-input performance8Change trigger: shared persistence or real multi-user access becomes required
The record is concise because it contains only the final tradeoff. It does not need a chronological account of every attempted library. Include an abandoned approach only when it explains a material constraint, such as discovering that a parser silently coerces missing numbers.

Inspect an actual transformation contract

A useful artifact specifies input and output rather than only naming a framework:
Input conditionRequired behavior
Closed ticket with large ageExclude from unresolved metric
Open ticket with missing ageRetain unknown count
Identical repeated ticket snapshotCollapse under declared delivery assumption
Conflicting repeated ID without orderReport ambiguity
No valid eligible rowsShow no known result, not a fabricated zero maximum
The last case matters. A maximum over an empty collection can produce a library-specific value that the UI formats as zero. Zero hours means a known fresh ticket under some contracts; no known age means no evidence for a maximum. The representation must preserve that difference.
A small pure transformation can be tested with local data even when the eventual application will call an API. That does not imply the API is verified. Keep the adapter boundary explicit so the reviewer can inspect domain behavior separately from transport behavior.

Spend the final hour on the largest contract gap

Assume three hours produced a correct normal result but the all-invalid fixture crashes the page. One hour remains. A useful final change handles the declared invalid/empty state, preserves diagnostics, and adds a regression fixture. A new chart would make the successful path richer while leaving a known required input path broken.
If the brief did not define invalid input behavior, state the assumption and choose a small sensible policy for the sample. Do not silently invent a broad product taxonomy. For example, reject the file with a count and representative safe error messages, or exclude invalid rows while showing counts, depending on the agreed output. Explain how that choice affects the total.
A reviewer may prefer a different policy. The decision record makes revision possible because the current rule and its consequences are visible. Hidden assumptions are harder to change than explicit provisional choices.

Change one requirement and recalculate scope

Shared editing by five users introduces authoritative persistence, identity, permissions, and concurrent updates. It does not automatically require many services. A single server and database can implement a small shared contract. A version precondition may reject stale writes, but the interface must preserve the draft and expose the conflict.
If time remains four hours total, add these guarantees by cutting optional reporting scope rather than claiming a much larger complete product. The artifact might become a single editable record with a two-user conflict demonstration instead of a broad dashboard. The revised deliverable should still be complete for its narrower purpose.
Another changed requirement could be an offline-only environment. That favors local persistence but introduces sync or export needs if results must later leave the device. The choice follows the actual contract, not a universal preference for local or hosted storage.

Misconceptions and a second exercise

One misconception is that temporary means the shortcut has no consequences. A shortcut inside the required correctness boundary is still a defect. Another is that a decision record proves the decision was right. It makes the reasoning inspectable; evidence can still reverse it.
Exercise: a library converts missing age to 0 and the fixture's largest known age remains 11, so the headline looks correct. Should the candidate accept it? No, because the unknown count and interpretation become wrong even if this maximum is unchanged. Add a fixture where every eligible age is missing and assert an unknown result. Award one point for identifying the hidden semantic defect, one for the new discriminating fixture, one for the corrected representation, and one for explaining the visible consequence.
In the final answer, connect the chosen scope, one rejected alternative, and the strongest verification. A reviewer should be able to ask what changes if an assumption changes and get a specific response.

Exercise and solution

The reviewer changes the requirement to shared edits by five users. Rewrite the decision. Local single-user state no longer satisfies the contract. Add authoritative persistence, authorization, and a concurrency rule, then reconsider scope to fit the available time. Award one point for identifying the failed assumption, one for the new guarantees, and one for cutting optional work rather than silently expanding the deadline.

Interview probe and wrap-up

Which shortcut are you most comfortable defending? A strong answer picks a shortcut whose limitation is outside the agreed scope and whose replacement boundary is clear. Follow up with one whose limitation affects correctness. A weak answer labels every shortcut temporary without a plan. A decision trail is valuable because it reveals when the choice should change, not because it makes the first choice permanent.

Sources

docsPostHog engineering work-sample guidanceposthog.comdocsMartin Fowler on starting with a monolithmartinfowler.comdocsAWS cost-optimization frameworkdocs.aws.amazon.com

Checkpoint

A work sample stores one user's edits in memory. Two authorized users must now edit the same record from separate devices and see committed changes. What must the decision record revisit?

AOnly the local save interval, because both users already have permission to open the app.BOnly the browser cache key, because identical keys establish one shared latest value.COnly the conflict banner, while each browser remains the independent authority for the record.DA shared persistence authority, current write permission, and a concurrency rule that prevents one user silently overwriting another.
Sign up free to answer and see why

Checkpoint

All eligible ages are missing. Which result preserves the metric?

AUse the largest closed-ticket age.BUnknown maximum with an explicit missing count.CZero as a known maximum.DDrop every missing row and claim complete data.
Sign up free to answer and see why

Checkpoint

One hour remains and a required all-invalid input crashes. Best priority?

AHandle the declared invalid state and add a discriminating regression fixture.BChange frameworks before checking the failure.CRemove invalid inputs from the instructions without disclosure.DAdd a second chart of the successful fixture.
Sign up free to answer and see why

Checkpoint

A candidate keeps data local for a single-user, offline work sample. Which rejected-alternative note gives a reviewer a useful change trigger?

AA server is unnecessary for every small product, so the decision needs no later review.BA server was rejected because the candidate knows the local library better; shared-device use will keep the same authority model.CA server adds deployment and synchronization work without meeting a current requirement; revisit shared persistence if edits must move between devices or users.DA server was rejected because it has higher setup cost; ignore any later durability or collaboration requirement until the work sample ends.
Sign up free to answer and see why

Checkpoint

Missing age becomes 0 but the current maximum stays 11. Is the transformation verified?

AYes, numeric coercion always preserves meaning.BNo; unknown counts and all-missing cases can be wrong despite this headline.CNo local fixture can test it.DYes, the headline is unchanged.
Sign up free to answer and see why

Can you write a decision record with assumptions, observable consequences, verification, and a trigger that would change the choice? State the relevant identifiers, failure boundary, and evidence in your own words before selecting your confidence.

Not yetGetting thereConfident

Sources

Free to read · better with Enzo

Learn it with Enzo

Save your progress, answer the checkpoints, and let Enzo quiz you on what you just read.