Directly start matching from k 'th index as  at-least k-1 characters will match
while ( i + k < n and j + k < n and txt [ i + k ] == txt [ j + k ] ) : NEW_LINE INDENT k += 1 NEW_LINE DEDENT lcp [ invSuff [ i ] ] = k NEW_LINE