Blockchain Developer
Solidity and the EVM questions
135 questions on Solidity and the EVM for blockchain developers, easiest first.
Easy 42
- What gas measureseasy
- Changing deployed codeeasy
- Letting a contract spend tokenseasy
- storage, memory, calldataeasy
- Why emit eventseasy
- Standard for unique tokenseasy
- What msg.sender iseasy
- The account nonceeasy
- EOA vs contract accounteasy
- Wei and ethereasy
- view vs pureeasy
- Sending ETH to a functioneasy
- receive vs fallbackeasy
- Reading a missing mapping keyeasy
- What revert undoeseasy
- What a modifier doeseasy
- Private variables are public dataeasy
- constant vs immutableeasy
- One contract, many token typeseasy
- Token decimalseasy
- Integer division resulteasy
- Where to try a deploymenteasy
- Foundry's local nodeeasy
- Why use OpenZeppelineasy
- Function selectoreasy
- Running out of gaseasy
- external vs internaleasy
- Sending ETH to a plain addresseasy
- Looping over a mappingeasy
- Default value of an enumeasy
- Overriding a parent functioneasy
- What an interface may containeasy
- The using ... for syntaxeasy
- Comparing two stringseasy
- What pragma ^0.8.20 allowseasy
- How much is one gweieasy
- Calculating a transaction feeeasy
- Do view functions cost gaseasy
- Calling as another address in a testeasy
- Seeing why a Foundry test failedeasy
- Reading past events on chaineasy
- A standard for yield vaultseasy
Medium 55
- Packing storage variablesmedium
- Custom errorsmedium
- Upgrading a proxy safelymedium
- Fuzz tests in Foundrymedium
- Overflow in Solidity 0.8medium
- Base fee and priority feemedium
- Predicting a CREATE2 addressmedium
- Refunding outbid biddersmedium
- Safer ownership transfermedium
- Tokens that return nothingmedium
- Fee-on-transfer token depositsmedium
- Approving with a signaturemedium
- expectRevert in the wrong placemedium
- Testing against real protocolsmedium
- Invariant testsmedium
- What Slither is good formedium
- Transient storage locksmedium
- Blobs and rollup feesmedium
- Reset that does not resetmedium
- UUPS vs transparent proxymedium
- Constructors behind a proxymedium
- Unlimited token approvalsmedium
- SELFDESTRUCT after Dencunmedium
- Roles instead of one ownermedium
- Working out a transfer feemedium
- How an upgradeable proxy worksmedium
- "Cannot estimate gas" before sendingmedium
- Filtering events by usermedium
- Effective gas price with a fee capmedium
- A transfer fee in rupeesmedium
- An implementation nobody initialisedmedium
- Reordering variables in an upgrademedium
- Adding a variable to a base contractmedium
- An initialize function without a guardmedium
- Signatures from smart walletsmedium
- Checking an upgrade before it shipsmedium
- What unchecked doesmedium
- transfer() fails for a smart walletmedium
- Ignoring a low-level call resultmedium
- Minimum gas for a transactionmedium
- Reading the same slot twicemedium
- Cost of a new storage valuemedium
- Contract too large to deploymedium
- msg.sender inside delegatecallmedium
- Relying on the contract balancemedium
- What try/catch can wrapmedium
- An update that does not stickmedium
- Storing history cheaplymedium
- Computing a fee in basis pointsmedium
- Removing an item from an arraymedium
- Length of a rupee stringmedium
- Testing a 7-day lockmedium
- Catching gas regressionsmedium
- Address of a contract made with newmedium
- Indexed event parametersmedium
Hard 38
- Paying everyone in a loophard
- delegatecall to user inputhard
- Account abstractionhard
- Reentrancy through safeMinthard
- EIP-7702 and "only EOAs" checkshard
- Namespaced storage layouthard
- Hash collision with encodePackedhard
- msg.value inside a multicallhard
- Which way to round in a vaulthard
- Constant product swap outputhard
- Return data gas griefinghard
- Relayer forwards too little gashard
- Using block.number for time on L2hard
- Deployment fails on one chainhard
- Why transparent proxies split callershard
- A fee that rounds to zerohard
- Expensive loop over storagehard
- The forgotten implementation contracthard
- Why the first storage write costs mosthard
- Scaling a price feed correctlyhard
- Why an L2 fee spikedhard
- Is block.timestamp safe to usehard
- Claiming someone's future wallethard
- Where a mapping value is storedhard
- Where array elements are storedhard
- How much refund clearing storage giveshard
- Memory in inline assemblyhard
- Very large memory arrayshard
- Price that comes out as zerohard
- Indexed strings in eventshard
- Order of super callshard
- Storing claim flags cheaplyhard
- A factory with a huge init codehard
- A view call that revertshard
- Libraries that must be linkedhard
- A try/catch that still revertshard
- A catch clause that does not matchhard
- Immutables behind a proxyhard