Pagini recente » Cod sursa (job #583343) | Cod sursa (job #823346)
Cod sursa(job #823346)
#include <fstream>
#include <cstring>
using namespace std;
const char iname[] = "text.in";
const char oname[] = "text.out";
ifstream fin(iname);
ofstream fout(oname);
char s[ 481624 ];
int lg , i , j , lgt , nr_cuv , vs , verita;
char a , b;
int x , y;
void VeritaSerum ()
{
while ( fin.get( a ) )
{
if( a >= 'a' && a <= 'z' || a >= 'A' && a <= 'Z' )
++x;
else
if( b >= 'a' && b <= 'z' || b >= 'A' && b <= 'Z' )
++y;
b = a;
}
}
int main()
{
VeritaSerum ();
fout << x / y << '\n';
return 0;
}