int test(int a,int b){
     if(a>=b) return 1;
     if(s[a]!=s[b]) return 0;
     if(vis[a][b]) return pal[a][b];
     vis[a][b]=1;
     
     return pal[a][b]=test(a+1,b-1);
 }

 

posted on 2023-01-07 21:36  towboat  阅读(32)  评论(0)    收藏  举报