-
Notifications
You must be signed in to change notification settings - Fork 193
Optimize is_subsequence function to linear time complexity #2135
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
base: main
Are you sure you want to change the base?
Conversation
Hi @reallesee! Thanks for the contribution. I left you some comments. |
Hey FrancoGiachetta, ready for review, thanks! |
@FrancoGiachetta all good, to be honest I got a bit confused — could you please check? |
Hi @reallesee, thanks for contributing. Are there any benchmarks that show improvements with this change? |
Hey @gabrielbosio New O(n) implementation results:
![]() |
TITLE
Optimize is_subsequence function to linear time complexity
Description
Improve performance by replacing repeated position() calls with a single-pass algorithm that maintains proper subsequence order checking.
Description of the pull request changes and motivation.
Checklist