whats wrong in my program??
int main()
{
int t;
cin>>t;
while(t--)
{
char s[100001];
long long int count=0,c=0;
cin>>s;
count=strlen(s)*(2+(strlen(s)-1))/2;
for(int i=0;i<strlen(s);i++)
{
if(s[i]=='7')
c++;
else
{ count=count-(c*(c+1))/2;
c=0;
}
}
count=count-(c*(c+1))/2;
cout<<count<<endl;
}
return 0;
}