SOCI4L

Leave a trail

Step 1 of 3
0 of 2 goals

Declare what you will announce

Above the function, add:

event Deposited(address indexed who, uint256 amount);

Nothing happens yet. An event is a shape, not an action.

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.24;

contract Vault {
    uint256 public total;

    function deposit(uint256 amount) external {
        total += amount;
    }
}

Goals

The contract compiles
nothing to compile yet
Declare `event Deposited`
nothing compiles yet

Contract storage

Write a contract and it will deploy itself here.