Your First 90 DaysAcademy
Writing With a Machine · Solidity, and the Tool That Writes It · Week 13 · Checkpoint 27

What It Gave You Reading

Fifty six lines that claim to implement ERC-20, and mostly do. Four ordinary passes over them, with the real interface pinned on the board beside, and four places come out where the file does not say what it appears to say.

15 steps~26 min3 nodes for your map
01 · The pass you already know how to make

The loop is three moves. You say what you want, you read what came back, you make it prove itself. The last checkpoint was the first move. This one is the middle move, and it asks nothing new of you at all.

This board is the real thing: OpenZeppelin's `IERC20`, pinned at a commit, the same file you read in week four. The board after it is not real code. It has no upstream, it was written for this lesson, and the step it appears on says so.

02 · What came back

This board is not a deployed contract and belongs to no repository. It was written for this lesson as a plausible answer to a request for an ERC-20 token, and it is hashed here so it cannot drift. Read it the way you read the last four acts.

Line 4 says what it claims to be: a token implementing the interface on the other board, exactly as that file declares it. Take the claim as a claim. Four passes over these fifty six lines, and the first is the one you have always made first.

03 · The state, before anything else

Every reading you have done in this course starts here. Lines 7 to 10 are four values the contract stores, line 12 is one entry per holder, line 13 is one entry per pair, and lines 15 and 16 are the two announcements the file can make.

That is the whole of what this contract remembers. Nothing below line 17 can change anything that is not on these lines. Four scalars, two mappings, two events, and the rest of the file is functions moving between them.

04 · Then the signatures

Second pass, and it is the signatures. Three functions carry the word `function` on lines 25, 34 and 39. Three more ways in carry no such word at all, because lines 10, 12 and 13 are marked `public` and that word does two jobs at once.

Count what a caller can actually reach before you scroll. The other board declares six functions, and a file claiming to implement it either offers all six or does not.

`IERC20` declares six functions: `totalSupply`, `balanceOf`, `transfer`, `allowance`, `approve` and `transferFrom`. Reading only this file, how many of the six can a caller reach, and where do they come from?
your balance2,400
BANK_DBowner: the bank
you2,400
what the app is actually showing you
BANK_DBowner: the bank
you2,400their pen
you hold a claim. they hold the pen.
your digital life
BANK · you2,400the bank ✍
INSTAGRAM · you2.1M followersMeta ✍
STEAM · you134 gamesValve ✍
AIRLINE · you58,200 milesthe airline ✍
four tables. zero pens that are yours.
BANK_DBowner: the bank
you2,400
DENIED
try both pens
PLATFORM_DBowner: the platform
her · 8 years2,000,000 followers
one automated decision away
BANK_DB · you · 2,400intentcompetencecontinuity
your row stands on all three
FTX_DBowner: FTX
you5 BTC
the backing vault●●●●●
the row stayed. the backing did not.
CARD_DBowner: your bank ✍
TV you never bought−1,100
fraud reversal+1,100
someone holds the pen, so someone can fix it
?_DBowner: nobody
youstill yours?
?
can a table exist that nobody owns?
?
?_DBowner: ̶n̶o̶b̶o̶d̶y̶
you100
no owner, no pen, no trust?
keeper 1
you100
keeper 2
you100
keeper 3
you100
keeper 4
you100
keeper 5
you100
no THE copy, only copies.
keeper 2
you100
keeper 3
you100
keeper 4
you100
keeper 5
you100
your copy
you100
five copies. one of them is yours.
one attacker
one attacker, ten thousand faces.
real machinesburned wattsnext page, sealed
writing costs watts. faking voters buys nothing.
cost paid OUTSIDE: hardware and power
proof of work, burn energy to vote.
page 1you · 100page 2you · 100page 3you · 100page 4you · 100
rewrite one line, break every lock after it.
office lunchtrusted keeperconsensusfive keepers, real cost
the price buys trustlessness. the office already has trust.
?
ownerless ledger
you?
a key, not a login?
nobody owns the table. so who owns your row?
reading against a pinned filetracing every namecomments as claims

Three new nodes on your map

reading against a pinned file · tracing every name · comments as claims · +10 Lynx