0_0_30431854_21535.cpp: In function 'int main()': 0_0_30431854_21535.cpp:66:47: error: 'len' was not declared in this scope printf("%d\n", cycle_len-slen%len);//把循环部分去掉,再用cycle_len减就是需要加上的,如abcab,3-5%3=1 ^