linea-tracer icon indicating copy to clipboard operation
linea-tracer copied to clipboard

fix: Fix issues in binary_search.sh

Open fragchain opened this issue 10 months ago • 2 comments

This update improves the JSON generation process by using jq, ensuring proper handling of quotes and spaces.

I've also fixed the issue with mid rounding, where it now correctly rounds up, preventing infinite recursion.

Additionally, checks have been added before recursion to ensure that we don't repeatedly call the same range:
if [ "$mid" -gt "$start" ] and if [ "$mid" -lt "$end" ].

This should prevent unnecessary loops and improve performance.

fragchain avatar Feb 01 '25 08:02 fragchain

CLA assistant check
All committers have signed the CLA.

cla-assistant[bot] avatar Feb 01 '25 08:02 cla-assistant[bot]