#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
#define OJ \
    freopen("input.txt", "r", stdin); \
    freopen("output.txt", "w", stdout);
int main(){
cin.tie(0);ios_base::sync_with_stdio(0);
int t;
cin>>t;
while(t--){
    string s;
    cin>>s;
    cout<<(int)s.size()<<"\n";
}
}

