One Code Many Storages

pragma solidity >=0.5.0 <0.6.0;contract Counter {
uint public counter;

function increment() public {
counter++;
}

function add(uint value) public {
counter += value;
}

function incrementFail() public {
counter++;
require(false, "fail error");
}

function fail() public pure {
require(false, "fail error");
}
}
Deploy Transaction for Counter.sol
data: 0x000000000000000000000000157973f817512a87a4f5eb12b1a1ec448d1d7049

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store