Skip to content

A collection of useful data structures and utilities I am putting together as part of other ongoing solidity projects.

Notifications You must be signed in to change notification settings

ModernExodus/solidity-data-structures-and-utils

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

solidity-data-structures-and-utils

A collection of useful data structures and other utils I've built while building different projects on the Ethereum blockchain.

Coming Soon

  • Completion of other common heap functions (heapify, extract, etc)
  • Median Heap (great solution for the moving median problem)
  • QuickSelect implementation (with Lomuto partitions)
  • Gas cost analysis
  • Node package available via npm

Contributions

All feedback and pull requests are welcome! If you see a way to optimize, please raise a PR! I will be happy to review and discuss any changes with you! I am adding items to this repo as I build them for other projects, so I am not focusing primarily on this and would greatly appreciate any help.

Project Structure

This project was created using Truffle CLI. Useful Commands:

  • truffle develop (spin up your own development blockchain)
  • truffle compile (compile all contracts)
  • truffle migrate (migrate all compiled contracts to development blockchain)
  • truffle test (run all unit tests)

Disclaimer

I do not guarantee these are completely optimized. Use of these implementations may or may not result in optimal gas costs for transactions. By the very nature of the current version of the Ethereum blockchain, operations with large amounts of data tend to be expensive. In the near future, I will be publishing some analysis of gas usage as well as making some optimizations.

License

Every thing I publish to this repository is available under the MIT license.

About

A collection of useful data structures and utilities I am putting together as part of other ongoing solidity projects.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published