Deployed a Advance Storage on XinFin XDC Network.

mahalakshmiper7

MahaLakshmi Perumal

Posted on November 12, 2020

Deployed a Advance Storage on XinFin XDC Network.

created a #SmartContract in Solidity language for a Advance storage, and successfully deployed on XinFin XDC Network under the injected web 3 environment.
Check the code:

pragma solidity >=0.5.0;
contract AdvancedContracts {
uint[] ids;
function add(uint id) public {
ids.push(id);
}
function get(uint position) public view returns(uint) {
return ids[position];
}
function getall() public view returns(uint[] memory) {
return ids;
}
function length() public view returns(uint) {
return ids.length;
}
}

💖 💪 🙅 🚩
mahalakshmiper7
MahaLakshmi Perumal

Posted on November 12, 2020

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related