an efficient way? i have a list of wallet addresses i need to add to a mapping
I can't think of anything more efficient than passing an array of addresses and looping through them to update your map.
Use a merkle tree or a set of signed coupons, super cheap
Never heard of that. Wait lemme google
Sounds interesting... can you link to any code examples of using a merkle tree/signed coupons in a solidity contract? I've never seen anything like that...
Super common for NFT mint whitelists, I've used several Merkle trees in my NFT contracts
This makes creating the whitelist cheaper but checking it more expensive tho, so that might depend on how he uses that and how big is the list of addresses to be whitelisted
Yeah, as long as you're using a list that is longer than like tens of items, it should make good gas sense
I've never heard of signed coupons but you can find a merkle tree also on uniswap's github
thanks, I'll check it out
Обсуждают сегодня