realise a Simple Swap contract
yarn install
yarn compile
yarn testyarn init
yarn add --dev hardhat
npx hardhat
yarn add --dev @openzeppelin/contracts
yarn add --dev solmate
yarn add --dev ethereum-waffle
yarn add --dev ethers@5.7.2
npx hardhat compile
npx hardhat testfor the signature validatiaon
Nonce must be incremental, but not necessarily to consecutive; However if it is not consecutive, it is not gas efficient.
bitmap to save gas, see Bitmap_Example