Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- instr = input()
- size = len(instr)
- for i in range(1, size+1):
- if size % i != 0:
- continue
- check = True
- for j in range(1, size//i):
- if instr[:i] != instr[j * i:(j+1) * i]:
- check = False
- break
- if check:
- print(size // i)
- break
Advertisement
Add Comment
Please, Sign In to add comment