版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA版权协议,转载请附上原文出处链接和本声明。
版权
提示:此题用string,会简单很多
#include#include#include#include#includeusingnamespace std;#define ll long long#include#define ull unsigned long longint ei[5]={1,2,4,8};intmain(){int t;scanf("%d",&t);while(t--){getchar(); string s; cin>>s;//	printf("%d\n",s.size()); string ss="";for(int i=0;i