Cod sursa(job #1013785)
Utilizator | Data | 21 octombrie 2013 19:05:05 | |
---|---|---|---|
Problema | Text | Scor | 30 |
Compilator | cpp | Status | done |
Runda | Arhiva de probleme | Marime | 0.28 kb |
#include<fstream>
using namespace std;
ifstream f("text.in");
ofstream g("text.out");
int a,b;
char c;
long long nr;
int main()
{
while(f.get(c))
{if(c>='a' && c<='z' || c>='A' && c<='Z') a=a+1;
else if(a!=0) b=b+1;
}
g<<a/(b-1)<<'\n';
g.close();
return 0;
}