Cod sursa(job #248654)

Utilizator ciorile.chioareBogatu Adrian ciorile.chioare Data 26 ianuarie 2009 14:35:36
Problema Text Scor 80
Compilator cpp Status done
Runda Arhiva de probleme Marime 0.44 kb
#include<stdio.h>
#include<string.h>
#include<string>

char x,y;

int m,n,cuv,lit;

int muu(int &lit)
{
	scanf("%c",&x);
	
	while(scanf("%c",&y)!=EOF)
	{
		if( (y>='A'&&y<='Z')||(y>='a'&&y<='z') )
		{
			lit++;
			if( (x<'A')||(x>'Z'&&x<'a')||(x>'z'))
				cuv++;
		}
		x=y;
	}
    return cuv;
}


int main()
{
    freopen("text.in","r",stdin);
    freopen("text.out","w",stdout);
   
 
	
	int n = muu(m);
    printf("%d",m/n);

	return 0;
}