This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@relation 'x' | |
@attribute 'instance_id' string | |
@attribute 'repetition' numeric | |
@attribute 'stacks' numeric | |
@attribute 'tiers' numeric | |
@attribute 'stack.tier.ratio' numeric | |
@attribute 'container.density' numeric | |
@attribute 'empty.stack.pct' numeric | |
@attribute 'overstowing.stack.pct' numeric | |
@attribute 'overstowing.2cont.stack.pct' numeric |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity 0.8.7; | |
import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; | |
import "@openzeppelin/contracts/access/Ownable.sol"; | |
import "./IERC20.sol"; | |
import "./IERC1155.sol"; | |
contract MultipleEditionClaimable is ReentrancyGuard, Ownable { | |
//token buy with any erc20 token | |
// function mintUser( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.4; | |
import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; | |
import "./IERC20.sol"; | |
contract StakingToken is ReentrancyGuard { | |
mapping(address => uint256) internal stakeholders; | |
uint256 private _totalSupply; | |
// IERC20 public stakingToken; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.4; | |
import "./IERC20.sol"; | |
contract Claimable { | |
uint256 internal claimableAmount = 10 * 10e18; | |
function claim(IERC20 _tokenAddress/*,address stakingSMAddress*/) external { | |
require(msg.sender != address(0), "Invalid address"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.4; | |
import "@openzeppelin/contracts@4.7.3/token/ERC20/ERC20.sol"; | |
contract BertilTokens is ERC20 { | |
uint256 internal fullAmountTokens = 10000 * 10**decimals(); | |
constructor(address _claimableToken,address _stakingAddress) ERC20("BertilTokens", "BATL") { | |
_mint(_claimableToken, fullAmountTokens); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity 0.8.7; | |
//rinkeby 0x2E772a6488A1592e6eB9d84CfBb7417AF6a039fd | |
contract ExampleRevert{ | |
uint256 private init; | |
function release_r()public view{ | |
require(init>100,"Revert error message from SC"); | |
} | |
function release_w()public{ | |
require(init>100,"Revert error message from SC"); | |
init=1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity 0.8.10; | |
// The goal of this challenge is to be able to sign offchain a message | |
// with an address stored in winners. | |
contract Challenge{ | |
address[] public winners; | |
bool lock; | |
function exploit_me(address winner) public{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity 0.8.10; | |
import "./Challenge.sol"; | |
contract Attack is Challenge { | |
Challenge public challenge; | |
address[] public _winners; | |
constructor(address _challengeAddress) { | |
challenge = Challenge(_challengeAddress); | |
// _winners=challenge.winners; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.3; | |
import "@chainlink/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol"; | |
import "@chainlink/contracts/src/v0.8/VRFConsumerBase.sol"; | |
import "@openzeppelin/contracts/access/Ownable.sol"; | |
import "hardhat/console.sol"; | |
//TODO: test with hardhat js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifer: MIT | |
pragma solidity ^0.8.3; | |
import "@chainlink/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol"; | |
library PriceConverter{ |
NewerOlder