Period of a string
Very easy
Execution time limit is 1 second
Runtime memory usage limit is 64 megabytes
The string s is given. Find the string t of minimum length such that s can be represented as a concatenation of one or some copies of t.
Input
One string s (1 ≤ |s| ≤ 5·10^6) that contains the latin letters only.
Output
The length of a string t.
Examples
Input #1
Answer #1
Submissions 1K
Acceptance rate 22%