Skip to content
KALANBLON
Show contents

Chapter 6 of 6 · 10 min

Quiz: smart contracts

Deterministic execution, gas, atomicity, reentrancy, the checks-effects-interactions pattern and pull refunds: check that you can write a robust contract. You need 70% correct answers to pass this quiz.

Quiz

7 questions · pass mark: 70%

  1. 1.Why must a smart contract's code be deterministic?

    One answer

  2. 2.What happens when a transaction runs out of gas during execution?

    One answer

  3. 3.Which mistake made the attack on The DAO possible in 2016?

    One answer

  4. 4.Complete the name of the pattern that protects against reentrancy: checks, effects, …

    Complete the code

  5. 5.Why use the block number rather than the computer's time for a deadline?

    One answer

  6. 6.Why avoid refunding every donor in a loop?

    One answer

  7. 7.Which checks must a fund's claim() function perform?

    Several answers possible

Your progress is saved on this device. Create a free account to keep your progress on all your devices.