xxxxxxxxxx
//this imports the ethers.js library
const ethers = require('ethers')
/**
* this is your new wallet address, this address shoukd never be used to send or purchase
* crypto before deploying smart contract
*/
const walletAddress = "0x331C0A6Bf81A16d366cc73f01Bf86DEfdC8E626A";
//here we are defining the nonce
const nonce = 0;
//This deployedAddress veriable uses the ethers.js library to get the contract address
//by computing the nonce and the wallet address
let deployedAddress = ethers.utils.getAddress(ethers.utils.getContractAddress({from: walletAddress, nonce}));
console.log(deployedAddress);
//Console will print 0x5489e3bF61dde8A04E53b3Ae54E3710E06B3E9ED