Prize puzzles are a unique use case for smart contracts and a great example of blockchains unlocking new functionality. The idea behind a prize puzzle is for a benefactor to put up a bounty for answering a question, using a smart contract to verifiably lock up the reward so that only the correct answer can unlock the contract.
In this chapter, we will create two types of prize puzzles: a simple puzzle that unlocks immediately when the answer is provided and a commit-reveal style puzzle that permits multiple winners. We will then ...