From 219b669ad876440bbc6f8e8e2d33e9d8623edba5 Mon Sep 17 00:00:00 2001 From: ox42 Date: Wed, 18 Feb 2026 01:07:08 +0100 Subject: [PATCH] Use uint256 --- README.md | 10 ++++++++++ contracts/Counter.sol | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 70c5473..8145b24 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,16 @@ This example project includes: +## Install + +To install dependencies, run: + +```shell +npm install +``` + + + ## Building To build, run: diff --git a/contracts/Counter.sol b/contracts/Counter.sol index d8dcda9..023b4cc 100644 --- a/contracts/Counter.sol +++ b/contracts/Counter.sol @@ -8,7 +8,7 @@ contract Counter { x++; } - function incBy(uint by) public { + function incBy(uint256 by) public { require(by > 0, "incBy: increment should be positive"); x += by; }