Back to Home

Ticket

0x2617fb1b5071...81ddc9a0430c
ByzantiumSource VerifiedEdit this contract
Deployed November 28, 2017 (8 years ago)Block 4,638,669

A lottery number you can pay by address: send ether here and it buys tickets for your chosen number on your behalf, refunding anything left over.

Byzantium EraVerified Source

Historical Significance

This is a user interface built out of addresses. Picking a lottery number normally means constructing a transaction with the right calldata; here the operator deploys one contract per number and a player only has to send ether to the right address, which any wallet can do. The cost is a contract deployment per number, paid once, and the benefit is that playing needs no ABI, no dapp and no wallet that understands contract calls.

Key Facts
Deployment Block
4,638,669
Deployment Date
Nov 28, 2017, 04:04 PM
Code Size
398.0 B

Description

Two values are fixed at construction: a number, exposed publicly as dream, and the lottery contract. The whole contract is a payable fallback.

Send it ether and it calls buyTicketsFor on the lottery, naming the sender as the buyer and the stored number as the pick. Whatever the lottery does not spend stays behind, so the fallback finishes by sending any remaining balance back to the sender. A call from the lottery itself returns immediately and does nothing, which is what stops the refund from re-entering the purchase.

There is no owner, no way to change the number, and no way to point it at a different lottery. Each deployment is one number, permanently.

Source Verified

Solidityeh_crack_source_verified
Compiler: v0.4.18

Bytecode Overview

Opcodes398
Unique Opcodes93
Jump Instructions18
Storage Operations8

External Links