Billy Rennekamp pfp
Billy Rennekamp
@okwme
I'm working on a new concept for a tournament that awards the "Most Average" score. It's called a "Bell Curve Tournament" since the winner is the "Most Mid". In the end it will be used on anybody.gg (@trifle) to run: ANYBODY BELL CURVE TOURNAMENT where ANYBODY CAN WIN
1 reply
1 recast
0 reaction

Billy Rennekamp pfp
Billy Rennekamp
@okwme
I realized that I needed to keep the average speeds of all players sorted to find the most mid, which is a difficult problem in computationally constrained environments like the EVM. Luckily there's a type of self-balancing binary search tree (BST) called a Red-Black Tree 🔴⚫️🌳
1 reply
0 recast
0 reaction

Billy Rennekamp pfp
Billy Rennekamp
@okwme
This clever data structure ensures that whenever you modify the tree it will only take O(log n) times to do so while keeping the whole group sorted. This is much better than O(n²) time it takes with most traditional sorting algorithms.
1 reply
0 recast
0 reaction

Billy Rennekamp pfp
Billy Rennekamp
@okwme
The ✨ magic of OSS ✨ is how it always seems to have a solution ready, thanks to others who’ve faced and solved the same problem before. @HitchensRob, who I worked with via @b9lab, has a great implementation based on one by @BokkyPooBah (who also made the best Solidity time lib).
1 reply
0 recast
0 reaction

Billy Rennekamp pfp
Billy Rennekamp
@okwme
Now I can efficiently track and reward the "Speedy", "Savory" and "Middy" players in our upcoming ANYBODY BELL CURVE TOURNAMENT where ANYBODY CAN WIN at anybody.gg. Follow @trifle for updates 📣
0 reply
1 recast
0 reaction