semeru/Code-Code-CloneDetection-POJ104 huggingface dataset:
int main()
{
	int i,m,j=0,k,max=0;
	int a[100],b[100];
	scanf("%d",&k);
	for(i=0;i<k;i++)
	{
		scanf("%d%d",&a[i],&b[i]);
	}
	for(i=0;i<k;i++)
	{
		if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90)
		{
			j=1;
			for(m=i+1;m<k;m++)
			{
				if(a[m]>=90&&a[m]<=140&&b[m]>=60&&b[m]<=90)
					j=j+1;
				else
				{
					j=j;
					break;
				}
			}
		}
		if(j>max) max=j;
		j=0;
	}
	printf("%d",max);
	return 0;
}
void main()
{
	int I,n,a[100],i,b[100],p=0,s=0,q=0,sum=0;

	scanf("%d",&n);

	for(I=0;I<n;I++)
	scanf("%d %d",&a[I],&b[I]);
	for(i=0;i<n;i++){
		if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90) q=1;
		if(q==1&&(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90)){
			if(i!=n-1) s++;
			else sum=sum>(s+1)?sum:(s+1);
		}
		if(q==1&&!(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90)){
			sum=sum>s?sum:s;
			s=0;
			q=0;
		}
	}
	printf("%d\n",sum);

}
int main(){
	int n;
	scanf("%d",&n);
	int s[100][2],a[100]={0};
	int i,j,e;
	for(i=0;i<n;i++){
		for(j=0;j<2;j++){
			scanf("%d",&s[i][j]);
		}
	}
	int c=0;
	for(i=0;i<n;i++){
		if(s[i][0]<=140&&s[i][0]>=90&&s[i][1]<=90&&s[i][1]>=60){
			c++;
		}else{
			a[i]=c;
			c=0;
		}
	}
	a[n-1]=c;
	for(i=1;i<n;i++){
		for(j=0;j<n-i;j++){
			if(a[j]<a[j+1]){
				e=a[j+1];
				a[j+1]=a[j];
				a[j]=e;
			}
		}
	}
	printf("%d",a[0]);
	return 0;
}
int main()
{
	int n,high,low,a[100],d=0,num;
	cin>>n;
	memset(a,0,sizeof(a));
	for(int i=1;i<=n;i++)
	{
		cin>>high>>low;
		if((high<=140)&&(high>=90)&&(low>=60)&&(low<=90))
		{
			a[d]=a[d]+1;
		}
		else
		{
			d=d+1;
		}
	}
	for(int i=0;i<99;i++)
	{
		if(a[i]>a[i+1])
		{
			num=a[i];
			a[i]=a[i+1];
			a[i+1]=num;
		}
	}
	cout<<a[99]<<endl;
	
	return 0;
}
int main(){
	int n,sz[100][2],i,j,t=-1,k=-1;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		for(j=0;j<2;j++){
		scanf("%d",&sz[i][j]);
		}
	}
	for(i=0;i<n;i++){
		if(sz[i][0]<=140&&sz[i][0]>=90&&sz[i][1]<=90&&sz[i][1]>=60){
			t++;
			if(k<t){
				k=t;
			}
		}else{ 
			if(k<t){
			k=t;
			}
			t=-1;
		}
	}
	k+=1;
	printf("%d",k);

	return 0;
}
int main(){
	int n,sz[100][2],i,s=0,j,a=0,p=0;
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		for(j=0;j<2;j++)
		{
		   scanf("%d",&(sz[i][j]));
		}
	}
	for(i=0;i<n;i++)
	{
		if((sz[i][0]<=140)&&(sz[i][0]>=90)&&(sz[i][1]>=60)&&(sz[i][1]<=90))
		{
			a+=1;
			s+=1;
			if(p<s)
			{
			   p=s;
			   s=s;
			   a=a;
			}
			else
			{
				p=p;
				s=s;
				a=a;
			}
		}
		else
		{
			if(p<s)
			{
			   p=s;
			   s=0;
			   a=0;
			}
			else
			{
				p=p;
				s=0;
				a=0;
			}
		}
	}
	printf("%d",p);
	return 0;
}
int main()
{
	int n,a,b,i;
	int count=0,t=0;
	scanf("%d",&n);
	for (i=1;i<=n;i++)
	{
		scanf("%d %d",&a,&b);
		if (a>=90 && a<=140 && b>=60 && b<=90)
			count++;
		else
			if (count>t)
			{
				t=count;
				count=0;
			}
			else
				count=0;
	}
	if (count>t)
	{
		printf("%d\n",count);
	}
	else
	{
		printf("%d\n",t);
	}
	return 0;
}
int main(){
int i,j,a[100],b[100],c[100],n,e;
scanf("%d",&n);
for(i=0;i<n;i++){
scanf("%d%d",&a[i],&b[i]);
}
for(i=0;i<n;i++){
c[i]=0;
}
j=0;
for(i=0;i<n;i++){
if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90) c[j]++;
if(!(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90)) j++;
}
for(i=0;i<n-1;i++){
	if(c[i]>c[i+1]){
e=c[i];
c[i]=c[i+1];
c[i+1]=e;
	}
	}
printf("%d",c[n-1]);
return 0;
}
int main(){
	int i=0,c=0,k=0,l=0;
	int a[50000],b[50000],h[50000],n;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d%d",&a[i],&b[i]);
	}
	for(i=0;i<n;i++){
			h[i]=0;
	}
	for(i=0;i<n;i++){
		for(l=i;l<n;l++){
			if(a[l]>=90&&a[l]<=140&&b[l]>=60&&b[l]<=90){
				h[i]++;
			}else{
				i=l;
				break;
			}
		}
	}
	for(i=0;i<n;i++){
		if(h[i]>k){
			k=h[i];
		}
	}

	printf("%d",k);


	return 0;
}
int main()
{
    int n,p[N],q[N],i,j,s,x,y;
    x=0;y=0;s=0;
    scanf("%d",&n);
    for(i=0;i<n;i++){scanf("%d%d",&p[i],&q[i]);}
    for(i=0;i<n;i++)
        {
            if(p[i]>=90&&p[i]<=140&&q[i]>=60&&q[i]<=90)
                {x=x+1;if(x>s){s=x;}}
            else
                {x=0;}
        }
    printf("%d",s);
    return 0;
}
int main(){
   int i, a=0, s=0,n, sz[100], ss[100];
   scanf("%d",&n);
   for(i=0;i<n;i++){
      scanf("%d",&ss[i]);
      scanf("%d",&sz[i]);
      if(ss[i]>=90&&ss[i]<=140&&sz[i]<=90&&sz[i]>=60){
      a=a+1;
      }
      else {
		  a=0;}
      if(a>=s){
		  s=a;}
    }
     printf("%d",s);
     return 0;
 }
int main(){
	int n,ss,sz,i;
	int max=0,lj=0;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d",&ss,&sz);
		if(ss<=140&&ss>=90&&sz>=60&&sz<=90)
			lj++;
		else{
			if(lj>max)
				max=lj;
			lj=0;
		}
	}
	if(lj>max)
		max=lj;
	printf("%d",max);
	return 0;
}
int main(){
	int a[100],b[100],c[100],n,i,m=0,k;
	for(i=0;i<100;i++){
		c[i]=0;
	}
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d",&a[i],&b[i]);
	}
	for(i=0;i<n;i++){
		if((a[i]>=90&&a[i]<=140)&&(b[i]>=60&&b[i]<=90)){
			c[m]++;
		}else{
			m++;
		}
	}
	for(k=0;k<m;k++){
		for(i=0;i<m-k;i++){
			int d;
			if(c[i]>c[i+1]){
				d=c[i+1];
				c[i+1]=c[i];
				c[i]=d;
			}
		}
	}
	printf("%d",c[m]);
	return 0;
}
int main (){
	int i,k[101] ,n,a,b,sum,j;
	k[0] =0;
	sum =0;
	cin >>n;
	i=1;
	for(i=1;i<=n;i=i+1)
	{
		cin >> a >> b;
	if (a>=90 &&a<=140&&b>=60&&b<=90)
		k[i] =k[i-1] +1;
	else k[i] =0;

	}
	for(j=1;j<=n;j++)
	{
		if (k[j]>=sum)
			sum =k[j];

	}
	cout << sum <<endl;
	return 0;

}
int main()
{
	int a[2][100];
	int n,i,max1,max2,m=0,p=0;
	scanf("%d", &n);
	for (i=0; i < n; i++)
	{
		scanf("%d",&a[0][i]);
		scanf("%d",&a[1][i]);
	}
	for (i=0; i < n; i++)
	{
		if(a[0][i] >= 90 && a[0][i] <= 140
			&& a[1][i] >= 60 && a[1][i] <= 90)
		{
			p++;
		}
		else
		{
			if(p > m)
				m=p;
			p=0;
		}
	}
	if(p > m)
		m=p;
	printf("%d",m);

}
int main(){
	int n,x,y,i,j,k=0,a[1000]={0},ex;
    scanf("%d",&n);
	for(i=0;i<n-1;i++)
	{
		scanf("%d%d",&x,&y);
		if (x<=140&&x>=90&&y<=90&&y>=60)
			a[k]++;
		else
			k++;
	}
	scanf("%d%d",&x,&y);
	if (x<=140&&x>=90&&y<=90&&y>=60)
	{
		a[k]++;
		k++;
	}
	else
		k++;
	for(i=0;i<k;i++)
	{
		if(a[0]<a[i])
		{
			ex=a[0];
			a[0]=a[i];
			a[i]=a[0];
		}
	}
	printf("%d\n",a[0]);
	return 0;
}
int main (){
	int n,t=0,s=0;
	int sz[100]={0},xueya[100][2];
	scanf("%d",&n);
	for(int i=0;i<n;i++){
		for(int a=0;a<2;a++){
			scanf("%d",&xueya[i][a]);
		}
	}
	for(int b=0;b<n;b++){
		if(xueya[b][0]>=90&&xueya[b][0]<=140&&xueya[b][1]>=60&&xueya[b][1]<=90){
			sz[t]++;
		}else{
				t++;
				}
		}
	for(int g=0;g<100;g++){
		if(sz[g]>s){
			s=sz[g];
		}
	}
	printf("%d",s);
	return 0;
}
//*********************
//???6            **
//??????       **
//???2013/10/23   **
//*********************
int main()
{
	int n, a, b, num, leap, max1, max;

	cin >> num;

	max = max1 = 0;

	n = 0;

	for ( int i = 1; i <= num; i++ )
	{
		cin >> a >> b;

	    leap = ( a <= 140 ) && ( a >= 90 ) && ( b <= 90 ) && ( b >= 60 );

		if ( leap )
		{
			n++;

			max = n;
		}
		else
		{	
			if ( max1 > max )
			{
				max = max1;
				
				n = 0;
			}
			else
			{
				n = 0;

				max1 = max;
			}
		}
	}
	if ( max > max1 )

		cout << max << endl;

	else

		cout << max1;

	return 0;
}
int main(){
    int n=0,i=0,j=0,k=0,s=0; //??3???????????0
    cin>>n; //??n
    int a[n],b[n],c[n+1]; //??????????????????????
    for(;i<n;i++){ //????
        cin>>a[i]>>b[i]; //?????????
        c[i]=0; //c[i]???0
        if (a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90) //??????
            c[k]=c[k]+1; //???????c?1
        else k=k+1; //?????c????????
    }
    c[n] = 0;
    c[n+1]=0; //?c[n+1]???????????
    for(;j<=k;j++){ //????
        if (s<c[j]) s=c[j]; //????????????????????????
    }
    cout<<s; //?????????
    return 0;
}
int main()
{
	int i,n;
	int a[max],b[max];
	int c=0,d=0;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d%d",&a[i],&b[i]);
		if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90){
			c++;
		
		
		if(c>=d){
			d=c;
		}
		}
		else{
			c=0;
		
		}
	}
	printf("%d",d);
	return 0;
}
int main()
{
	int n;
	int i=0;
	scanf("%d",&n);
	//int m;
	
	int a[200];
	int time[100];
	//m=2*n;
	for(i=0;i<200;i++)
		a[i]=0;
	for(i=0;i<100;i++)
		time[i]=0;
	for(i=0;i<2*n;i++)
		scanf("%d",&a[i]);
	int m=0;
	for(i=0;i<2*n;i=i+2)
	{
		if(a[i]>=90&&a[i]<=140&&a[i+1]>=60&&a[i+1]<=90)
			time[m]++;
		else
			m++;
	}
	int max=0;
	for(i=0;i<100;i++)
	{
		if(time[i]>max)
			max=time[i];
	}

	printf("%d\n",max);
	return 0;
}
int main(){
	int n,i,c,d;
	int s[110][2];
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d",&s[i][0],&s[i][1]);
	}
	if(s[0][0]>=90&&s[0][0]<=140&&s[0][1]>=60&&s[0][1]<=90){
		c=1;
	}
	else{
		c=0;
	}
	d=c;
	for(i=1;i<n;i++){
		if(s[i][0]>=90&&s[i][0]<=140&&s[i][1]>=60&&s[i][1]<=90){
			c=c+1;
		}
		else{
			c=0;
		}
		if(c>d){
			d=c;
		}
	}
	printf("%d",d);
		return 0;
}
int main()
{
	int hours;
	cin >> hours;
	int maxNormHours = 0;
	int normHours = 0;
	for (int i=1 ; i<= hours ; i++)
	{
		int max,min;
		cin >> max >> min;
		if ((max >= 90) && (max <= 140)&&
			(min <= 90) && (min >= 60) == 1)
			normHours ++;
		else
		{
			if (normHours > maxNormHours)
				maxNormHours = normHours;
			normHours = 0;
		}
	}
	if (normHours > maxNormHours)
	maxNormHours = normHours;
	cout << maxNormHours << endl;
	cin.get();
	cin.get();
	return 0;
}
void main()
{
int c=0,n,i,t=0,a[100],b[100];
scanf("%d\n",&n);
for(i=0;i<n;i++)
scanf("%d %d\n",&a[i],&b[i]);
for(i=0;i<n;i++)
{
	if((a[i]>=90)&&(a[i]<=140)&&(b[i]>=60)&&(b[i]<=90))
					c++;
	else 
			{if(c>t)
				t=c;
	c=0;}

}
if(c>0)
{
if(c>t)
t=c;
}
printf("%d\n",t);
}
int main()
{
	int n,i=0,h[100],l[100],t[101]={-1,0},len[100],j=0;
	int max=0,r=0;
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		scanf("%d%d",&h[i],&l[i]);
	}
	i=0;
	while(h[i],l[i])
	{
		while(h[i]>=90&&h[i]<=140&&l[i]>=60&&l[i]<=90)
			i++;
		t[j+1]=i;
		len[j]=t[j+1]-t[j]-1;
		j++;
		i++;
	}
	for(r=0;r<j;r++)
	{
		if(len[max]<len[r])
			max=r;
	}
	printf("%d",len[max]);
	return 0;
}
int main(){
	int sum=0,t=0;
	int n;
	scanf("%d",&n);
	for(n;n>0;n--){
	int a,b;
    scanf("%d %d",&a,&b);
	if(a>=90 && a<=140 && b>=60 && b<=90){
		sum=sum+1;
		if(t<=sum){
			t=sum;
		}
	}
	else{sum=0;
	}
	}
printf("%d",t);
return 0;
}
int main()
{
	int x,y,i,n;
	int a[100];
	int b[100];
    scanf("%d",&n);
	i=0;
	while(i<n)
	{
		scanf("%d %d",&(a[i]),&(b[i]));
	    i++;
	}
	y=0;

	i=0;
	while(i<n)
	{  x=0;
		while(i<n)
	   {
	      if((a[i])>=90&&(a[i])<=140&&(b[i])>=60&&(b[i])<=90)
	      {x++;}
	      else break;
	      i++;
	   }
		if(x>=y)
		{y=x;}
    i++;
	}
	if(n==1)
	{  if((a[0])>=90&&(a[0])<=140&&(b[0])>=60&&(b[0])<=90)
		printf("1");
	else
		printf("0");
	}
	else printf("%d",y);
	return 0;
}
int main()
{ 
	struct a
	{
		int x,y;
	}as[100];
	int n,i,j,k,m;
	int b[100];
	scanf("%d",&n);
	for(i=0;i<n;i++) scanf("%d%d",&as[i].x,&as[i].y);
	j=0;b[j]=0;
	for(i=0;i<n;i++)
	{
		if(((as[i].x>=90)&&(as[i].x<=140))&&((as[i].y>=60)&&(as[i].y<=90))) b[j]=b[j]+1;
		else { j=j+1;b[j]=0;}
	}
	k=j;
	for(j=0;j<=k;j++)
	{
		m=0;
		for(i=0;i<=k;i++)
		{
			if(b[j]<b[i]) m=1;
		}
		if(m==0){printf("%d",b[j]);break;}
	}
	return 0;
}
int main()
{
	int n,i,j,count[1000],high[1000],low[1000];
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		scanf("%d%d",&high[i],&low[i]);
	}
	for(i=0;i<n;i++)
	{
		count[i]=0;
		for(j=i;j<n;j++)
		{
			if(high[j]<=140&&high[j]>=90&&low[j]>=60&&low[j]<=90)
				count[i]++;
			else break;
		}
	}
	for(i=1;i<n;i++)
	{
		if(count[0]<count[i])
			count[0]=count[i];
	}
	printf("%d",count[0]);
	return 0;
}
int main()
{
    int a,b,n,hours1=0,hours2=0,max,i=1;
    scanf("%d",&n);
    for(i=1;i<=n;i=i+1)
	{
		scanf("%d %d",&a,&b);
        if(a>=90&&a<=140&&b>=60&&b<=90)
        hours1=hours1+1;
        else 
			if(hours2<=hours1)
		{
				hours2=hours1;
                hours1=0;
		}
			else
				hours1=0;
	}
    if(hours1>hours2)
    max=hours1;
    else
    max=hours2;
    printf("%d",max);
    return 0;
}
int main(int argc, char* argv[])
{	
	int a[100],b[100],c[100];
	int i,n,h,e;
	scanf("%d\n",&n);
         for(i=0;i<100;i++)
             {a[i]=0;
             b[i]=0;
             c[i]=0;}
	for(i=0,c[-1]=0;i<n;i++)
	{scanf("%d %d",&a[i],&b[i]);
	if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90)
		c[i]=c[i-1]+1;
	else
		c[i]=c[i-1]*0;
	}
	for(e=0;e<n;e++)
		for(i=0;i<n-e;i++)
			if(c[i]<c[i+1])
			{h=c[i];
			 c[i]=c[i+1];
			 c[i+1]=h;
			}
	printf("%d\n",c[0]);
	return 0;
}
int main()
{
  int n,a,b,c=0,t=0,i=1,max=0;
  cin>>n;
  for(i=1;i<=n;i++)
  {  
	  cin>>a>>b;
      if(a>=90&&a<=140&&b>=60&&b<=90)
          c=c+1;
	  else
		{  
	        c=0;
	  }
	  t=c;
		if(t>max)
		 max=t;  
  }

  cout<<max;
  return 0;
}
int main(){
    int n;
    scanf("%d",&n);
    int sz[n][2],i;
    for(i=0;i<n;i++){
        scanf("%d%d",&sz[i][1],&sz[i][2]);
    }
    int sz2[n],j=0;
        for(i=0;i<=n;i++){
        sz2[i]=0;

    }
    for(i=0;i<n;i++){
        if(sz[i][1]>=90&&sz[i][1]<=140&&sz[i][2]>=60&&sz[i][2]<=90)
        {
            sz2[j]++;
            
        }else{
            j++;
        }
    }
    int max=0;
    for(i=0;i<=j;i++){
        if(sz2[i]>max){
            max=sz2[i];
        }
    }

    printf("%d",max);

    return 0;
}
int main(){
    int n,x,y,a,s=0,i=1,u=0;
    scanf("%d",&n);
    while(i<=n){
     scanf("%d %d",&x,&y);
     if(x<=140&&x>=90&&y<=90&&y>=60){
      s++;
      }
       if(s>u){
       u=s;
       }
      if(x>140||x<90||y>90||y<60){
       s=0;
       }
       i++;
     }
      printf("%d",u);
      return 0;
}
int main()
{
	int n;
	int q[100]={0};
	cin>>n;
	int i=0,j=0,a,b,max=0;
	for(i=1;i<=n;i++)
	{
		cin>>a>>b;
		if(a>=90&&a<=140&&b>=60&&b<=90)
			q[j]++;
		else
			j++;
	}
	for(i=0;i<100;i++)
	{
		if(q[i]>max)
			max=q[i];
	}
	cout<<max<<endl;
	return 0;
}
int main(){
    int n,b,i,k;
    scanf("%d",&n);
    b=0;
    k=0;
    i=1;
    while(i<=n){
                int a,f;
                scanf("%d %d",&a,&f);
                if(a>=90&&a<=140&&f>=60&&f<=90){
                                                b+=1;
                                                }else{
                                                      if(b>k){
                                                              k=b;
                                                              b=0;
                                                              }else{
                                                                    k=k;
                                                                    b=0;
                                                                    }
                                                              }
                                                              i+=1;
                                                              }
    if(b>k){
            k=b;
            }else{
                  k=k;
                  }
    printf("%d",k);
                  
 return 0;
}
//????
int main()
{
	int n = 0, i = 0, x = 0, y = 0, sum = 0, max = 0;
	cin >> n;
	for (i = 1; i <= n; i++)
	{
		cin >> x >> y;
		if ( x >= 90 && x <= 140 && y >= 60 && y <= 90)
		{
			sum++;
		}
		else
			sum = 0;
		if (sum > max)
			max = sum;
	}
	cout << max << endl;
	return 0;
}
int main(){
    int n,a,b,result=0,i=1,max=0;
    scanf("%d",&n);
    while(i<=n){
    scanf("%d%d",&a,&b);
    if(a>=90&&a<=140&&b>=60&&b<=90){
    result+=1;
    i++;
    }else{
    if(result>max){
    max=result;
    result=0;
    i++;}
    else{
    result=0;
    i++;}
    }
    }
    if(result>max){
       max=result;}
    printf("%d",max);
    return 0;
}
int main()
{
    int n,i,j=0,h=0;
    int sz[100][2];
    int sfzc[100]={0};
    int lxsc[100]={0};
    scanf("%d",&n);
    for(i=0;i<n;i++)
    {
        scanf("%d%d",&sz[i][0],&sz[i][1]);
    }
    for(i=0;i<n;i++)
    {
        if((90<=sz[i][0])&&(sz[i][0]<=140))
        {
            if((60<=sz[i][1])&&(sz[i][1]<=90))
            {
                sfzc[i]=1;
            }
        }
    }
    for(i=0;i<n+1;i++)
    {                               
        if(sfzc[i]==1)
        {
            j++;
        }
        else
        {
            lxsc[i]=j;
            j=0;
        }
    }
    for(i=0;i<n+1;i++)
    {
        if(h<lxsc[i])
        {
            h=lxsc[i];
        }
    }
    printf("%d",h);
    return 0;
}
int main(){
	int n,i,a[100],d,k=0,b[100],c[100]={0};
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d%d",&a[i],&b[i]);
	}
	for(i=0;i<n;i++){
		if((a[i]>=90)&&(a[i]<=140)&&(b[i]>=60)&&(b[i]<=90)){
			c[k]++;
		}
		else{
			k++;
		}
	}
	if((a[n-1]>=90)&&(a[n-1]<=140)&&(b[n-1]>=60)&&(b[n-1]<=90)){
		k++;
	}
	for(i=0;i<k-1;i++){
		if(c[i]>c[i+1]){
			d=c[i+1];
			c[i+1]=c[i];
			c[i]=d;
		}
	}
	printf("%d",c[k-1]);
	return 0;
}
int main()
{
 int a,b,max=0,t=0,n,i;
 scanf("%d",&n);
 for(i=1;i<n;i++){
	scanf("%d %d",&a,&b);
	if(a>=90&&a<=140&&b>=60&&b<=90){t++;}
	else{
		if(t>=max){max=t;}
		t=0;
	}
	}
 scanf("%d %d",&a,&b);
 if(a>=90&&a<=140&&b>=60&&b<=90){t++;}
 if(t>=max){max=t;}
  printf("%d",max);
 return 0;
}
int main(){
	int a[100]={0};
	int s=0,b1,b2;
	int i,n,t,max=0;
	scanf("%d",&n);
	for(i=1;i<=n;i++){
		scanf("%d%d",&b1,&b2);
		if(b1>=90&&b1<=140&&b2>=60&&b2<=90){
			s++;
			if(s>max){
				max=s;
			}
		}else{
			s=0;
		}
		
	}
		printf("%d",max);
	
	return 0;
}
int main(){
     int count,m=0,n,i,j,k;
     scanf("%d",&n);
     int sz[N],a[N],b[N];
     for(i=0;i<n;i++){
        scanf("%d %d ",&a[i],&b[i]);
     }
     for(i=0;i<n;i++){
        if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90){
            count=1;
            for(j=i+1;j<n;j++){
                 if(a[j]>=90&&a[j]<=140&&b[j]>=60&&b[j]<=90){
                      count++;
                 }else{
                      break;
                 }
            }
            sz[m]=count;
            m++;
        }
     }
     for(i=0;i<m-1;i++){
        if(sz[i]>sz[i+1]){
            k=sz[i];
            sz[i]=sz[i+1];
            sz[i+1]=k;
         }
     }
     printf("%d",sz[m-1]);
     return 0;
}
int main()
{
    int n,m=0,h=0,i;
    scanf("%d",&n);
    int a[n],b[n];
    for(i=0;i<n;i++){scanf("%d%d",&a[i],&b[i]);}
    for(i=0;i<n;i++){
                     if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90){m=m+1;if(h<m){h=m;}
}
                     else{if(h<m){h=m;}
                          m=0;}
                    }
   printf("%d",h); 
return 0;
    }
int main()
{
int n,i,j,k,t;
int a[100][2]={0};
int b[101]={0};
b[0]=0;
k=0;
scanf("%d\n",&n);
for(i=0;i<n;i++)
{
  for(j=0;j<2;j++)
  scanf("%d",&a[i][j]);
}
for(i=0;i<n;i++)
{
	k=i+1;
	if(90<=a[i][0]&&a[i][0]<=140&&60<=a[i][1]&&a[i][1]<=90)
	{
    b[k]=b[k-1]+1;
	}
	else
	{
	b[k]=0;
	}
}
for(i=0;i<n;i++)
{
for(j=0;j<n-i;i++)
 if(b[i]>b[i+1])
 {
 t=b[i];
 b[i]=b[i+1];
 b[i+1]=t;
 }
}
printf("%d",b[n]);
return 0;
}
int main()
{
	int a[1000],b[1000],i,n,m[100]={0},k,j=0,max=0;
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		scanf("%d%d",&a[i],&b[i]);
	}
	for(i=0;i<n;i++)
	{
		if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90)
		{
			m[j]++;
		}
		else
			j++;
	}
	k=j+1;
	for(j=0;j<k;j++)
	{
		if(m[j]>max)
			max=m[j];
	}
	printf("%d",max);
	return 0;
}
int a[100],b[100],c[100];
int main(){
	int n,i,lh=0,k,e=0;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d",&a[i],&b[i]);
	}
	for(i=0;i<n;i++){
		c[i]=0;
	}
	for(i=0;i<n;i++){
		if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90){
			c[i]=1;
		}
	}
	for(i=0;i<n;i++){
		for(k=i;;k++){
			if(c[k]==1)
				lh++;
			else if(c[k]!=1)
				break;
		}
		//printf("%d\n",lh);
		if(e<lh){
			e=lh;
			lh=0;
		}
		else lh=0;
	}
	printf("%d",e);
	return 0;
}
//*?????(5-6) ???? **
//*????? 1300012893 **
//*???2013.10.25 **
int main()
{  
    int m1,high,low,i,h,n;//?????? m1?high??????low??????i???????h?????????n?????? 
    cin >> n;//??????n 
    m1 = 0; //????m1 
   for(i = 0;i < n;)//?????? 
  {   
    h = 0;//??????0 
   while(cin >> high >> low )//??????????? 
    {    
      i = i + 1;
       if (( high >= 90 )&&( high <= 140 )&&( low >= 60 )&&( low <= 90))//?????? 
       {
         h = h + 1;}//????? 
      else if(( high < 90)||( high > 140 )||( low < 60 )||( low > 90 ))//??????  
       {
          break;}
      if(h > m1)//????? 
      m1 = h;//???? 

    }
    }
     cout<<m1<<endl;//????????? 
     return 0;
}
//***********************************************************
//* ? ??5.cpp                                            *
//* ? ??? ? 1200012916                                 *
//* ? ??2012?10?12?                                   *
//* ? ??????????????????                 *
//***********************************************************

int main() 
{                                //?????
	int c1 = 0, c2 = 0, t = 1;   //??????????????  
	
	//??????????????a?b?
	//????????????c,??????i?n
	int a, b, c, i, n;          
    cin >> n;                    //??n
	for (i = 1; i <= n; i++)
	{
		cin >> a >> b;
		
		//?????????1?0??????
		if (a >= 90 && a <= 140 && b >= 60 && b <= 90)
			c = 1;
		else
			c = 0;
		
		//?if?????????????1?
		//????????????????c1?
		if (t == 1)          
		{
			if (c == 1)
			{
				c1 = c1 + 1;
				t = 1;
			}
			else
				t = 0;
		}
	    
		//??????0??c1?c2???
		//??????c2,??c1?0
		else                          
		{
			if (c1 > c2)
				c2 = c1;
			c1 = 0;
			if (c == 1)
			{ 
				c1 = c1 + 1;
				t = 1;
			}
			else
				t = 0;
		}
		
		//??c1?c2??????????c2
		if(c1 > c2)
			c2 = c1;
	}
	cout << c2 <<endl;           //??c2
	
	return 0;
}                                //?????
int main(){
   int c[100],n,i,j=0;
   scanf("%d",&n);
   for(i=0;i<n;i++){
	   c[i]=0;
   }
   int a,b;
   for(i=0;i<n;i++){
	   scanf("%d%d",&a,&b);
	   if(a>=90&&a<=140&&b>=60&&b<=90)
		   c[j]++;
	   else{
		   j++;
	   }
   }
   int m;
   for(i=0;i<n;i++){
	   for(j=0;j<n-1;j++){
		   if(c[j]<c[j+1]){
			   m=c[j];
		       c[j]=c[j+1];
			   c[j+1]=m;
		   }
	   }
   }
   printf("%d",c[0]);
	getchar();
	getchar();
		return 0;
}
int main(){
	int n,a,b,k=0,m=0;
	scanf("%d",&n);
	for(int i=1;i<=n;i++){
		scanf("%d%d",&a,&b);
		if(a>=90&&a<=140&&b>=60&&b<=90){
			m++;
		}else{
			if(m>k){
				k=m;
				
			}
				m=0;
		}
	}
	if(k>m){printf("%d",k);

	}else{printf("%d",m);

	}
	
	return 0;
}
/*
 * 1.cpp
 *
 *  Created on: 2012-10-8
 *      Author: Lixurong
 */


int main()
{
	int n; //????
	cin >> n; //??
	int s=0, h=0; //??????
	for( int i=0; i<n; i++ ) //??
	{
		int a, b; //????
		cin >> a >> b; //??
		if( (90-a<=0)+(140-a>=0)+(b-60>=0)+(b-90<=0)==4 ) //??
		{
			s++;
			h = max( s, h);
		}
		else
			s = 0;
	}
	cout << h; //??
	return 0;
}
//????


int main()
{
	int n,high[100],low[100],count=0,time_max=0;  //?? ?? ?? ???? ??????
	cin>>n;
	for(int i=0;i<n;i++)                       //????
		cin>>high[i]>>low[i];
	for(int i=0;i<n;i++)
	{
		if(high[i]>=90&&high[i]<=140&&low[i]>=60&&low[i]<=90)    //?????????????+1
		{
			count+=1;
			if(i==n-1)
				time_max=(count>time_max)?count:time_max;
		}
		else                                                     //??????????????????????????
		{
			time_max=(count>time_max)?count:time_max;
			count=0;                                       //??????
		}
	}
		cout<<time_max<<endl;
	return 0;
}
//********************************
//*??????? **
//*?????1300062805 **
//*???2013.10.27 **
//********************************
int main()
{
	int n, i, j, a, b,m=0;
	cin >> n;
	for ( i = 1; i <=n;)
	{
		j = 0;
		while (cin >> a >> b)
		{
			i++;
			
		if ((a>=90)&&(140>=a)&&(b>=60)&&(90>=b))
		{
			j++;
		}
		else
		{
			break;
		}
		if ( j > m)
			m=j;
		}
	}
	cout << m << endl;
	return 0;
}
int main(){
	int n,a,b,i;
	int	j=0;
	int zs[100];
	int t=0;
	for(i=0;i<100;i++){
		zs[i]=0;
	}
    scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d%d",&a,&b);
		if(90<=a&&a<=140&&60<=b&&b<=90){
			t++;
		}
		else{
			zs[j]=t;
			j++;
			t=0;
		}
	}	
	j=j+1;
	zs[j+1]=t;
	int max=0;
	for(i=0;i<100;i++){
	
		if(zs[i]>max)
			max=zs[i];
	}
	printf("%d",max);
	return 0;
}
int main (){
	int n;
	int s[100],q[100],t[100];
	
	
	int i;
	int j=0;
	int m;
	scanf ("%d",&n);
	for (i=0;i<n;i++){
		t[i]=0;
	}
	
	for (i=0;i<n;i++){
		scanf ("%d %d",&s[i],&q[i]);
		if (s[i]>=90&&s[i]<=140&&q[i]<=90&&q[i]>=60){
			t[j]++;
			
		}else if (i>=1&&s[i-1]>=90&&s[i-1]<=140&&q[i-1]>=60&&q[i-1]<=90){

				j++;
			
		}
	}
	for (i=0;i<n-1;i++){
		
			if (t[i]>t[i+1]){
				m=t[i];
				t[i]=t[i+1];
				t[i+1]=m;
			}
		
	}




		



	

    printf ("%d",t[n-1]);




    


	return 0;
}
int main()
{
 int n,i,k,m[10];
 float r=0,g=0;
 scanf("%d",&n);
 for(i=0;i<n;i++)
 {
  scanf("%d",&m[i]);
  r+=m[i];
 }
 for(i=0;i<n;i++)
 {
  scanf("%d",&k);
  if(k<60) g+=0*m[i];
  else if(k<=63) g+=1.0*m[i];
  else if(k<=67) g+=1.5*m[i];
  else if(k<=71) g+=2.0*m[i];
  else if(k<=74) g+=2.3*m[i];
  else if(k<=77) g+=2.7*m[i];
  else if(k<=81) g+=3.0*m[i];
  else if(k<=84) g+=3.3*m[i];
  else if(k<=89) g+=3.7*m[i];
  else g+=4.0*m[i];
 }
 printf("%.2f\n",g/r);
}