- zkLTC faucet: get here, connect wallet, click on faucet and select zkLTC
- liteforge network, add here
- visit remix
- sign in with your github
- create a new workspace (blank template)
- go to contracts and create a new file
- name it counter.sol
- paste this code
//SPDX-LICENSE-IDENTIFIER:MIT
pragma solidity ^0.8.19;
contract Counter {
uint256 public count;
event CountChanged(uint256 newCount);
constructor(uint256 _initialCount) {
count = _initialCount;
}
function increment() public {
count += 1;
emit CountChanged(count);
}
function decrement() public {
require(count > 0, "Count cannot go below zero");
count -= 1;
emit CountChanged(count);
}
function getCount() public view returns (uint256) {
return count;
}
}
b. go to compile
- click on compile
c. deploy
- go to deploy
- on environment, change from remix vm to browser extension then select your evm wallet
- manually switch to liteforge network
Deploying
- enter any numerical value in the box and deploy
- sign transaction