public int[] FindAllOccurrences_IDM_Test(string text, string pattern) { return(RabinKarp.FindAllOccurrences(text, pattern).ToArray()); }
public void FindAllOccurrences_IndexCheck(string t, string p, int[] expectedIndices) { List <int> result = RabinKarp.FindAllOccurrences(t, p); Assert.AreEqual(result, new List <int>(expectedIndices)); }