1 #define _for(i,a,b) for(int i = (a);i < b;i ++) 2 3 bool judge(string s,int i,int j,int len) 4 { 5 _for(k,0,len) 6 if(s[i]!=s[j]) 7 return false; 8 else 9 i ++,j ++;10 return true;11 }12 class Solution13 {14 public:15 int longestDecomposition(string text)16 {17 int i = 0;18 int j = text.size()-1;19 int lastj = j;20 int rnt = 0;21 while(i