Skip to main content

Smart Contracts — What and Why (Level 3)

Smart contracts are programs that execute on a distributed ledger to automatically enforce simple rules when conditions are met.

Simple explanation

Smart contracts look like regular code but run in an environment where their actions are recorded on a ledger. They are useful for automating escrow, simple financial rules, and token behaviour.

Risks and considerations

  • Bugs are expensive: code on a public ledger can be immutable and hard to fix.
  • Gas/fees: executing contracts on some networks costs money.
  • Legal & governance: running code does not necessarily equal legal compliance.

Short exercise

  1. Read a simple smart contract (many tutorials have annotated examples). Identify the inputs, outputs, and one possible failure mode.