A commercial invoice
An invoice whose lines and totals fall where the text puts them, and whose square code lets a telephone pay the exact sum into the exact account with nothing retyped.
A counter till prints on a roll 80 mm across, and a roll has no bottom edge: the paper is cut where the basket ends. So the page is as long as what was bought, and not a figure on it is written down beforehand. A line comes to its quantity times its unit price, the tax at each rate is taken out of the gross that carries it, and the change is what is left of the note handed over. Ring up one article more and the roll grows by one line, with the totals still under it.
The barcode at the foot is what the shop scans when the ticket comes back — a return, an exchange, a warranty claim. Nothing chooses its code set by hand: the library reads the ticket number, finds nothing in it but digits, and packs it two digits to a symbol, 112 modules where spelling the number out character by character would take 189. Whether it scans is for a scanner to say, and one does say: a decoder is pointed at the rendered page and reads the number back.
Nothing is left out and nothing is simplified: this is the program exactly as it runs, for whoever writes your software.
Read the Rust source Read the Python source
An invoice whose lines and totals fall where the text puts them, and whose square code lets a telephone pay the exact sum into the exact account with nothing retyped.
The note that travels with the goods: a barcode against each article, a box the receiver ticks, and the consignment's own code.
A payslip: eighteen contribution lines with employee and employer shares, the month against the year to date.
A services agreement over two pages where no clause is ever cut in half by a page turn, ending in signature, name and date fields filled in on screen.
A certificate whose border, ribbon and seal are drawn as lines rather than photographed: sharp at any size, and a fraction of the weight.
A boarding pass carrying, as a square code, the one line the gates at an airport read — one character out of place and it is refused.