Pagini recente » Cod sursa (job #2652530) | Cod sursa (job #2689787) | Cod sursa (job #445723) | Cod sursa (job #2194581) | Cod sursa (job #2101004)
#include <bits/stdc++.h>
using namespace std;
ifstream in ( "text.in" );
ofstream out ( "text.out" );
char v[] = "qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM";
bool ok = false;
int main()
{
char s[300000];
in.getline(s,300000);
int nrcuv=0;
int lgtotal=0;
for ( int i = 0 ; i < strlen(s) ; ++i )
if(strchr(v,s[i])!=0)
{
lgtotal ++ ;
if ( ok == false )
{
ok = true;
nrcuv ++;
}
}
else ok=false;
out <<lgtotal/nrcuv;
return 0;
}