Question · Blockchain and Web3 course · Module 6: Solidity Basics

The view Modifier

What does the 'view' modifier mean in a Solidity function?

Answer options

  • The function can modify the contract's state
  • The function only reads the state, it doesn't modify it
  • The function can accept payments
  • The function is visible only to the owner

You can check the correct answer by solving this task in the CodeWorlds game.