Skip to content

Instantly share code, notes, and snippets.

@AbhinavXT
Created December 19, 2021 04:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AbhinavXT/7a9ea55b2eac95acbd265e134d3d216a to your computer and use it in GitHub Desktop.
Save AbhinavXT/7a9ea55b2eac95acbd265e134d3d216a to your computer and use it in GitHub Desktop.
// SPDX-License-Identifier: GPL-3.0
pragma solidity >=0.7.0 <0.9.0;
contract MyContract {
// state variable num
uint256 public num;
// function sets value of variable num equal to _num
function setNum(uint256 _num) public returns(uint256) {
num = _num;
return num;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment