public void LongestCommonPrefix() { // Arrange var input = "ABABBAB"; var sa = new SuffixArray(input); // Act var lcp = sa.CreateLCPArray(); // Assert CollectionAssert.AreEqual(new[] {0, 2, 2, 0, 1, 3, 1}, lcp); }