Add Arrays library with unit tests (#1209) (#1375)
* Add Arrays library with unit tests (#1209)
* prepared due to snapshot token requirements
* add library with method to find upper bound
* add unit test for basic and edge cases
* Imporove documentation for Arrays library
Simplify Arrays.test.js to use short arrays as test date
* Added comment for uint256 mid variable.
* Explaned why uint256 mid variable calculated as Math.average is safe to use as index of array.
Showing
contracts/mocks/ArraysImpl.sol
0 → 100644
contracts/utils/Arrays.sol
0 → 100644
test/utils/Arrays.test.js
0 → 100644
Please
register
or
sign in
to comment