You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Improved distance calculation speed when a maximum cost is set.
- Reduced complexity from O(max(|s1|,|s2|)*maxCost) to O(min(|s1|,|s2|)*maxCost).
- Bypass the calculation when distance is guaranteed to be greater than maxCost.
- Added tests for more edge cases.
Improved distance calculation speed when a maximum cost is set.
- Reduced complexity from O(|s1|*|s2|) to O(max(|s1|,|s2|)*maxCost).
- Ignore maxCost when it would not help shorten the calculation.