← All Cryptocurrency Flashcard Decks

Smart Contracts and dApps Flashcards

7 cards from real Cryptocurrency practice questions. Tap to flip, then mark Knew It or Still Learning — missed cards come back until you master them.

Read the first 7 Smart Contracts and dApps flashcards as text
  1. What is a 'reentrancy attack' in the context of smart contracts?

    Answer: A bug where a contract calls itself recursively to drain funds before state updates

    In a reentrancy attack, a malicious contract repeatedly calls back into the vulnerable contract before its balance is updated, draining its ETH — famously exploited in The DAO hack.

  2. Which Ethereum Improvement Proposal (EIP) introduced the standard interface for fungible tokens?

    Answer: EIP-20

    EIP-20 (also called ERC-20) defines the standard interface for fungible tokens on Ethereum, enabling interoperability across wallets and exchanges.

  3. What does 'gas limit' represent in an Ethereum transaction?

    Answer: The maximum units of computational work the sender allows the transaction to consume

    The gas limit caps how many computational steps a transaction may execute; if execution exceeds this limit, the transaction reverts but the gas spent is still consumed.

  4. In Solidity, what does the 'view' function modifier indicate?

    Answer: The function reads state but does not modify it

    'view' functions promise not to alter blockchain state, so they can be called off-chain for free without submitting a transaction.

  5. What is the primary purpose of an oracle in a smart contract ecosystem?

    Answer: To supply real-world external data to on-chain contracts that cannot access it natively

    Blockchains are deterministic and isolated, so oracles act as trusted data feeds that bring off-chain information (prices, weather, sports scores) onto the chain.

  6. Which smart contract upgrade pattern keeps the contract logic separate from its storage?

    Answer: Proxy pattern

    The proxy pattern routes calls through an immutable proxy contract to a replaceable logic contract, allowing upgrades without migrating user balances or addresses.

  7. What does 'ABI' stand for in the context of smart contracts?

    Answer: Application Binary Interface

    The ABI (Application Binary Interface) defines how to encode function calls and decode return values when interacting with a compiled smart contract.