Cod sursa(job #1933825)

Utilizator alex273Groza Alexandru alex273 Data 20 martie 2017 22:44:32
Problema Text Scor 100
Compilator cpp Status done
Runda Arhiva de probleme Marime 0.28 kb

#include <bits/stdc++.h>
using namespace std;
ifstream f("text.in");ofstream g("text.out");
long long i,w,n;
char c;
bool k;
int main()
{
while(f.get(c))
{
if(c >= 'a' and c <= 'z' || c >= 'A' and c <= 'Z')
n++,k= 1;
else
if(k)
w++,k= 0; i++;
}
g<< n/w;
f.close();  g.close();
return 0;
}