题目链接:点击这里
长度为
的
种情况已经全部出现过,长度为
的
种情况也已经出现过,因此我们一定能够利用长度为
或
的字母去填充,因此答案就是
。
#include<iostream>
#include<algorithm>
#include<string>
#include<cstdio>
#include<cstring>
#include<cmath>
#include<stack>
#include<queue>
using namespace std;
typedef long long ll;
const int MOD = 10000007;
const int INF = 0x3f3f3f3f;
const double PI = acos(-1.0);
const int maxn = 1010;
int a[maxn];
int main()
{
ios::sync_with_stdio(0);
cin.tie(0);
cout.tie(0);
int t;
string s;
cin>>t;
while(t--)
{
cin>>s;
int len = s.length();
cout<<len/2<<endl;
}
return 0;
}