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
I would like to add this function that returns a list containing the starting indices of all the occurrences of a pattern string (say p : size m) within a text string (say t : size n)
Time Complexity : O(n+m)
Space complexity : O(n+m), to calculate the longest prefix suffix (lps) array and also return all indices of occurrences.
The text was updated successfully, but these errors were encountered:
I would like to add this function that returns a list containing the starting indices of all the occurrences of a pattern string (say p : size m) within a text string (say t : size n)
The text was updated successfully, but these errors were encountered: