This file contains hidden or 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
| // We require the Hardhat Runtime Environment explicitly here. This is optional | |
| // but useful for running the script in a standalone fashion through `node <script>`. | |
| // | |
| // When running the script with `hardhat run <script>` you'll find the Hardhat | |
| // Runtime Environment's members available in the global scope. | |
| const hre = require("hardhat"); | |
| const ethers = hre.ethers; | |
| const {BigNumber} = require("@ethersproject/bignumber/lib/bignumber"); | |
| const erc20Abi = [{"inputs":[],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount0","type":"uint256"},{"indexed": |
This file contains hidden or 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
| const fs = require('fs'); | |
| const cliArgs = process.argv.slice(2); | |
| const data = fs.readFileSync(cliArgs[0], 'UTF-8'); | |
| const tree = JSON.parse(data); | |
| const dfs = (todo, acc) => { | |
| if(todo.length === 0) return acc; | |
| const [name, node] = todo[0]; | |
| todo = todo.slice(1); |
This file contains hidden or 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
| <?php | |
| /** | |
| * SplClassLoader implementation that implements the technical interoperability | |
| * standards for PHP 5.3 namespaces and class names. | |
| * | |
| * http://groups.google.com/group/php-standards/web/final-proposal | |
| * | |
| * // Example which loads classes for the Doctrine Common package in the | |
| * // Doctrine\Common namespace. |