Skip to content

Instantly share code, notes, and snippets.

View shahzaintariq's full-sized avatar
👨‍🎓
Studying

Shahzain Tariq shahzaintariq

👨‍🎓
Studying
View GitHub Profile
@shahzaintariq
shahzaintariq / IERC.sol
Created February 21, 2020 19:39
ERC Interface
pragma solidity ^0.6.1;
interface ERC20TokenInterface {
function totalSupply() external view returns (uint);
function name() external view returns (string memory);
function symbol() external view returns (string memory);
function decimals() external view returns (uint);
function balanceOf(address tokenOwner) external view returns (uint256);
function allowance(address tokenOwner, address spender) external view returns (uint remaining);
function transfer(address to, uint tokens) external returns (bool success);
@shahzaintariq
shahzaintariq / abstract.sol
Created January 12, 2020 05:50
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.5.12+commit.7709ece9.js&optimize=false&gist=
pragma solidity ^0.5.0;
interface IAbsCal{
function add(uint _a,uint _b) external returns(uint);
function sub(uint _a,uint _b) external returns(uint);
function mul(uint _a,uint _b) external returns(uint);
function div(uint _a,uint _b) external returns(uint);
}
@shahzaintariq
shahzaintariq / asg1class.sol
Created December 30, 2019 08:18
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.5.11+commit.c082d0b4.js&optimize=false&gist=
pragma solidity ^0.5.11;
contract class{
struct bank {
string name;
uint age;
bool ispaid;
}
bank hbl;
@shahzaintariq
shahzaintariq / asg1class.sol
Created December 22, 2019 05:59
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.5.11+commit.c082d0b4.js&optimize=false&gist=
pragma solidity ^0.5.11;
contract class{
struct bank {
string name;
uint age;
bool ispaid;
}
bank hbl;