-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update Integer Square Root Function #117
Conversation
Codecov Report
@@ Coverage Diff @@
## main #117 +/- ##
==========================================
+ Coverage 53.23% 53.25% +0.01%
==========================================
Files 337 337
Lines 42984 42991 +7
Branches 360 362 +2
==========================================
+ Hits 22883 22895 +12
+ Misses 17671 17670 -1
+ Partials 2430 2426 -4
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
This is awesome @chgorman ! Overall the PR LGTM, just fix the formatting issues on the new contract. You can do it by running:
If you don't like the output of the linter on this file, just put it to be ignored in the |
I ran the linter. I do think the previous version is better as it is a bit easier to understand in some parts (like the bit length computation), but that is fine. |
Scope
Update Integer Square Root function and add additional tests for gas consumption.
Why?
This version of integer square root function has proof of convergence;
it also reduces gas from an average of 1283 to 1259 per call.