085. Pattern Two
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output

Though you may have completed the previous task to analyze and find patterns in sections of text, the FBI has realized that it needs a more powerful program that is able to find more complex patterns and with more constraints. Your new program should be able to identify if a repetition pattern exists within a string regardless of where it starts. You will also be supplied with a number that represents how many repeats there should be. Your program should only output "True" if the number of repetitions precisely matches the number provided.

Input

The first line contains the string to be analyzed. The second line contains a single integer that represents the number of repetitions to look for.

Output

A single statement of "True" or "False" that indicates whether or not a repetition pattern exists with the repeat number provided.

Example
Input
uyboubawlefjbasdHELLOHELLOHELLOHELLOsygvfubklkj
4
Output
True
Note

There can be unneeded text before and after the repetition, and this should be ignored.