Cod sursa(job #464461)
Utilizator | Data | 20 iunie 2010 12:24:32 | |
---|---|---|---|
Problema | Text | Scor | 100 |
Compilator | cpp | Status | done |
Runda | Arhiva de probleme | Marime | 0.3 kb |
using namespace std;
#include<fstream>
ifstream f("text.in");ofstream g("text.out");
char c;
int lung,nrcuv,x;//initial nule
int main()
{
while(f.get(c))
if(c>='a' && c<='z' || c>='A' && c<='Z'){nrcuv=x+1;lung++;}
else x=nrcuv;
g<<lung/nrcuv;
f.close();g.close();
return 0;
}