Beanie Baby Sales Contract

Loading...
# Initialization
init:
	#*** An Ethereum smart contract to sell 1 Beanie Baby for "500 by December"
	# First, store buyer's ethereum address:
	contract.storage["BUYER"] = 
    # Then, store seller's ethereum address:
    contract.storage["SELLER"] = 
    # January 1, 2016 is 1420099200 in "computer time"
    contract.storage["DEADLINE"] = 1420099200
code:
	#If the agreed amount is received on time
	if (contract.balance >= 500*10^18 and block.timestamp <= contract.storage["DEADLINE"]):
	# ... the  Beanie Baby is now shipped to the buyer's address
	contract.storage["BUYER_ADDRESS"] = contract.storage["BUYER"]
	send(contract.storage["SELLER"], contract.balance, (tx.gas - 100))
	

Serpent contract for Ethereum

Sell 1 Beanie Baby for $500

Preferences

Note: Your changes won't be saved, because not Logged-in.

Create your own Contract