Your First 90 DaysAcademy
The Grammar · Contracts Talking to Contracts · Week 6 · Checkpoint 14

Calling a Stranger

A hundred and twenty lines that are not a contract, do not deploy, and exist for one reason: a token may hand back nothing, and nothing is not the same as no. Read the library, then decide where to stop.

14 steps~26 min3 nodes for your map
01 · A file you will use without ever holding it

Your contract is holding an `IERC20`. Behind that address is a token somebody else wrote, whose code you have not read and cannot open from inside your own. Before you move any of it you reach for this file, and the first thing worth noticing is that the word `contract` never appears in it.

A hundred and twenty lines, and none of them will ever sit at an address you can point at. Working out what that sentence means is most of the checkpoint. The last beat is a window further down the same file, where the language changes.

02 · Three imports and a path that names the job

A licence, a release stamp, and a pragma with a ceiling above it, because a file with working code in it wants one. Read the path on line 2 as well: `utils`, sitting under `token/ERC20`. This is filed as a helper for the standard rather than as a piece of it.

Three imports follow. Line 8 brings in `IERC20`, the interface your own code already carries. The other two name interfaces this file can also work with. Nothing imported here is a contract either, which is starting to be a pattern rather than a coincidence.

03 · The word standing where `contract` would be

Line 19 opens the body, and the keyword in front of the name is `library`. Every file you have read so far opened with `contract`, `abstract contract` or `interface`. This is the fourth kind of thing a `.sol` file can declare, and it does not behave like any of the three.

You know what a contract carries: stored values, a constructor, an address once it is deployed. Decide which of those a library keeps before reading another line. Scan down from 19 for what is missing as much as for what is there.

Line 19 says `library` where every file so far said `contract`. What does that word change?
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?
libraryusing forinternal

Three new nodes on your map

library · using for · internal · +10 Lynx