Content
@
0 reply
0 recast
0 reaction
Noah Bragg ๐ฅ
@nbragg
Solidity devs: How possible is it to store a large array to hold a leaderboard onchain? It would need to be updated as it changes and shifted around. My gut reaction as that this would be too expensive to make happen. Is on a layer2 at least. Or are there any better solutions?
7 replies
0 recast
5 reactions
flick the dev ๐ฉ๐ฆ
@flick
it all you need is to go from score to rank and rank to score (but not, for example, rank to player) then sparse trees and a little magic could possibly work https://github.com/0xFlicker/ranker/blob/main/src%2Franker%2Franker.ts
1 reply
0 recast
1 reaction
Noah Bragg ๐ฅ
@nbragg
this sin't onchain though is it?
1 reply
0 recast
1 reaction
flick the dev ๐ฉ๐ฆ
@flick
no, it's just an efficient ranking algorithm I have used in web2
1 reply
0 recast
1 reaction