Class ZAlgorithm
A Z-algorithm implementation for string search.
Inherited Members
Namespace: Advanced.Algorithms.String
Assembly: Advanced.Algorithms.dll
Syntax
public class ZAlgorithm
Methods
Search(String, String)
Returns the start index of first appearance of pattern in input string. returns -1 if no match.
Declaration
public int Search(string input, string pattern)
Parameters
Type | Name | Description |
---|---|---|
String | input | |
String | pattern |
Returns
Type | Description |
---|---|
Int32 |