This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Efficient SQRT method | |
| // Constant gas cost of 293 discounting RETURN and CALLDATALOAD logic, or 311 including everything. | |
| // | |
| // Special thanks to @caironeth for have found a better log2(x) here: | |
| // - https://github.com/Lohann/openzeppelin-contracts/pull/1 | |
| // | |
| // For testing use this tool: https://www.evm.codes/playground?fork=cancun | |
| // Authors: | |
| // - Lohann Paterno Coutinho Ferreira <[email protected]> | |
| // - Cairo <https://github.com/cairoeth> |