{"trustable":false,"sections":[{"title":"","value":{"format":"PLAIN","content":"rxx很皮,今天又找到了新玩儿法。\n\nrxx给你一个字符串,并问你在该字符串末尾最少补充多少个字符,可以使得这个字符串获得周期性。\n\n周期性指存在一个子串,使得该字符串可以正好分解成若干个这个子串,且周期数大于1。"}},{"title":"Input","value":{"format":"PLAIN","content":"第一行是一个整数 T ( 0\u003cT\u003c\u003d100 ) 代表测试数据的组数。\n之后T行每行一个字符串,由小写字母组成,字符串的长度3\u003c\u003dL\u003c\u003d100000。"}},{"title":"Output","value":{"format":"PLAIN","content":"每组数据输出一行结果。"}},{"title":"Sample Input","value":{"format":"PLAIN","content":"3\nppp\npip\namazing"}},{"title":"Sample Output","value":{"format":"PLAIN","content":"0\n1\n7"}}]}