Pagini recente » Diferente pentru problema/zc intre reviziile 1 si 18 | Cod sursa (job #771662) | Cod sursa (job #1527305) | Cod sursa (job #1546245) | Cod sursa (job #1555882)
#include<fstream>
#include<cstring>
using namespace std;
ifstream f("text.in");
ofstream g("text.out");
int n,c1,q1,ok;
char c[1234567];
int main()
{
f.get(c,'\n');
n=strlen(c);
int a=0;
while(a<n)
{
if((c[a]>='A' && c[a]<='Z') || (c[a]>='a' && c[a]<='z'))
{
++c1;
if(ok==0)
{
++q1;
ok=1;
}
}
else
ok=0;
++a;
}
g<<c1/q1<<'\n';
return 0;
}