Skip to content

Wrong lemma in two_way_notes.txt #132088

@hugopm

Description

@hugopm

Hi @sweeneyde @tim-one

I think there is a wrong claim in the notes about two-way algorithm.

If p is a substring of s and p has period r, then the period
of s is either equal to r or greater than len(p).

Let s = (abcccd)^2 = abcccdabcccd and p = ccdabcc of length len(p) = 7 and period r = 5.

The period of the whole string s is 6, which is strictly greater than r but strictly smaller than len(p).

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsDocumentation in the Doc dir

    Projects

    Status

    Todo

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions