const ethers = require('ethers'); //安装ethers库
const provider = new ethers.providers.JsonRpcProvider('https://avalanche-c-chain.publicnode.com');
const senderPrivateKey = 'privatekey'; //填你的私钥
const wallet = new ethers.Wallet(senderPrivateKey, provider);
const loopCount = 10000; //这里设置你要打多少次 (一次一张)
async function main() {
for (let i = 0; i < loopCount; i++) {
const gasPrice = await provider.getGasPrice();
console.log(`当前gasPrice为${gasPrice.toString()},开始打印`);
const tx = {
to: wallet.address, //填你铭文的接收地址
value: 0,
gasPrice: gasPrice.mul(110).div(100), //拉高gasPrice到当前值的10%
gasLimit: 2202