Skills Flashcards
7 cards from real NFT practice questions. Tap to flip, then mark Knew It or Still Learning โ missed cards come back until you master them.
Read the first 7 Skills flashcards as text
What is the difference between 'view' and 'pure' functions in Solidity?
Answer: view reads state but doesn't modify it; pure neither reads nor modifies state
A view function can read blockchain state without changing it, while a pure function neither reads nor writes state.
Which approach helps reduce gas costs when minting many NFTs at once?
Answer: Batch minting using ERC-1155 or ERC721A
Batch-minting standards like ERC721A and ERC-1155 optimize storage writes to lower per-token gas costs.
What does an 'allowlist' (whitelist) mechanism control in an NFT mint?
Answer: Which wallet addresses are permitted to mint during a restricted phase
An allowlist restricts minting to pre-approved addresses, often verified via a Merkle proof, during early phases.
Why are Merkle trees commonly used for NFT allowlists?
Answer: They allow efficient on-chain verification of membership without storing every address
Merkle trees let a contract verify an address is on the list using a compact proof, saving storage and gas.
What is the purpose of the 'require' statement in Solidity?
Answer: To validate conditions and revert the transaction if they fail
require checks a condition and reverts the transaction with an optional message if the condition is false.
When auditing an NFT smart contract, why is the 'onlyOwner' modifier important?
Answer: It restricts sensitive functions to the contract owner's address
The onlyOwner modifier ensures privileged functions like withdrawing funds can be called only by the authorized owner.
What does 'delegatecall' do in Solidity, and why is it security-sensitive?
Answer: It executes another contract's code in the caller's context, which can expose storage to manipulation
delegatecall runs external code using the calling contract's storage, so a malicious target can corrupt state if misused.