semeru/Code-Code-CloneDetection-POJ104 huggingface dataset:
int main()
{
    int n,i,t,max;
	int ss[100];
	int sz[100];
	int time[100]={0};
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d/n",&ss[i],&sz[i]);
	}
	t=0;
    for(i=0;i<n;i++){
		if(ss[i]>=90&&ss[i]<=140&&sz[i]<=90&&sz[i]>=60){t++;time[i]=t;}
		else{t=0;}
	}
	max=0;
    for(i=0;i<n;i++){
		if(max<time[i]){max=time[i];}
	}
	printf("%d",max);
	return 0;

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

    return 0;
}
int main(){
int n;
scanf("%d",&n);
int sh[100],s[100];
int z[100];
for(int i=0;i<100;i++){
z[i]=0;
   }
for(int i=0;i<n;i++){
scanf("%d  %d",&sh[i],&s[i]);
   }
for(int u=0;u<n;u++){
for(int i=u;i<n;i++){
if(sh[i]<=140&&sh[i]>=90&&s[i]>=60&&s[i]<=90){
z[u]++;
            }
else{
break;
}
      }
     }
int t=0;
for(int i=0;i<n;i++){
if(t<z[i]){
t=z[i];
  }
 }
printf("%d",t);
return 0;
}
int main(){
int n,i,j,k=1,m=0,x=0;
    int cs[100],sz[100],a[100];
    scanf("%d",&n);
    for(i=0;i<n;i++){
      scanf("%d",&cs[i]);
      scanf("%d",&sz[i]);
    }
    for(i=0;i<n;i++){
      if(cs[i]<=140&&cs[i]>=90&&sz[i]<=90&&sz[i]>=60){
        a[i]=1;
      }else{
        a[i]=0;
      }
    }
    if(n==1){
      if(a[0]==1)
        m=1;
    }else{
      for(i=1;i<n;i++){
        j=i-1;
        if(a[j]==1&&a[i]==1){
          k++;
          if(k>m)
            m=k;
        }else{
          k=1;
          if(k>m)
            m=k;
        }
      }
    }
    for(i=0;i<n;i++){
      if(a[i]==1)
        x++;
    }
    if(x==0)
      m=0;
    printf("%d",m);
return 0;
}
int main(){
    int n,i,t=0,max=0;
	int a[Max];
	int b[Max];
	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)){
		   t++;
           if(t>max){
             max=t;
		     }
		} else{ 
			
			t=0;
		}
	
	}
	printf("%d",max);
	return 0;
}
int main(){
	int n,i,j=0,r=0;
	int l[100];
	int s[3][100];
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d",&s[0][i],&s[1][i]);
	}
	for(i=0;i<n;i++){
		if((s[0][i]<=140)&&(s[0][i]>=90)&&(s[1][i]<=90)&&(s[1][i]>=60)){
			s[2][i]=1;
		}else{
			s[2][i]=0;
		}
	}
   for(i=0;i<n-1;i++){
	   if(s[2][i]==1){
		   r++;
	   }
	   if(s[2][i]==0){
			   l[j]=r;
			   j++;
			   r=0;
		   }
   }
	   if(i==n-1){
		   if(s[2][i]==1){
		   r++;
            l[j]=r;
	   }
	   if(s[2][i]==0){
			   l[j]=r;
		   }

   }
   int max=0;
   for(i=0;i<=j;i++){
	   if(max<l[i]){
		   max=l[i];
	      }
   }
   printf("%d",max);
   return 0;
}
int main()
{
    int n;
    int a,b;
    int j=0,k;
    scanf("%d",&n);
    int*pp;
    pp=(int*)malloc(sizeof(int)*n);
    if(n==1)
    {
            scanf("%d%d",&a,&b);
             if((a>=90)&&(a<=140)&&(b>=60)&&(b<=90))
             {
                   j++;
             }
             else
             {
                  j=0;
             }
             printf("%d",j);
    }
    else
    {
        for(k=0;k<n;k++)
        {
             scanf("%d%d",&a,&b);
             if((a>=90)&&(a<=140)&&(b>=60)&&(b<=90))
             {
                   j++;
             }
             else
             {
                  j=0;
             }
             *(pp+k)=j;
         }
         for(k=0;k<(n-1);k++)
         {
             if(*(pp+k)>=*(pp+k+1))
             {
                  *(pp+k+1)=*(pp+k);
             }
         }
         free(pp);
         printf("%d",*(pp+n-1));
    }  
    return 0;
}
int main()
{
	int n, a, b, norm[100], num[100];
	cin >> n;
	for(int i =	1; i <= n; i++)
	{
		cin >> a >> b;
		num[i] = 0;
		if(a >= 90 && a <= 140 && b >= 60 && b <= 90)
			norm[i] = 1;
		else
			norm[i] = 0;
	}
	for(int i = 1; i <= n; i++)
	{
		for(int j = i; j <= n; j++)
		{
			if(norm[j] == 1)
				num[i] = num[i] + 1;
			else
				break;
		}
	}
	for(int i = 2; i <= n - 1; i++)
		num[1] = num[1] >= num[i]? num[1]:num[i];
	cout << num[1] << endl;
	return 0;
}
int main(){
	int n,a,b,i,x[100]={0},y[100]={0},s=0,k,m,e; 
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d%d",&a,&b);
		if((a>=90&&a<=140)&&(b<=90&&b>=60)){
			x[i]=1;
		}
	}
	for(i=0;i<n;i++){
		if(x[i]==1){
			while(x[i]==1){
				y[s]=y[s]+1;
				i++;
			}
			s=s+1;
		}
	}
	for(k=1;k<=s;k++){
		for(m=0;m<s-k+1;m++){
			if(y[m]<y[m+1]){
				e=y[m];
				y[m]=y[m+1];
				y[m+1]=e;
			}
		}
	}
	printf("%d",y[0]);
	return 0;
}
int main(){
	int n;
	int a,b;
	int sum=0;
	int i;
	int c=0;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d",&a,&b);
		if(a>=90&&a<=140&&b>=60&&b<=90){
			sum++;
		}
		else{
			if(sum>c){
				c=sum;
			}
			sum=0;
		}
	}
	if(c>=sum){
	printf("%d",c);
	}
	if(c<sum){
		printf("%d",sum);
	}

	return 0;
}
int main()
{
    int i,n,shrink,diastole,normal=0,max=0;
	scanf("%d",&n);
    for(i=0;i<n;i++)
	{
		scanf("%d %d",&shrink,&diastole);
        if(shrink>=90&&shrink<=140&&diastole>=60&&diastole<=90)
		{
			if(i==n-1)
			{
				normal++;
				if(normal>max)
				max=normal;
			}
			else
				normal++;
		}
		else
		{
			if(normal>max)
				max=normal;
			normal=0;
		}
	}
	printf("%d\n",max);
}
int main(){
int ss[100],sz[100],time[100];
int n;
int t=0,i=0,a=0;
scanf("%d",&n);
time[0]=0;
while(t<n){
scanf("%d %d",&ss[t],&sz[t]);
if(ss[t]>=90&&ss[t]<=140&&sz[t]>=60&&sz[t]<=90){
i+=1;
a+=1;
time[a]=i;
}else{
i=0;
}
t++;
}
int s=0,max=0;
while(s<=a){
    scanf("%d",&time[s]);
if(max<time[s]){
max=time[s];
}
s++;
}
printf("%d",max);
return 0;
}
int main()
{
    int n,u;
    u=0;
    scanf("%d\n",&n);
    int x[1000],y[1000],t[100];
    for(int i=0;i<100;i++){
        t[i]=0;
    }
    for(int i=0;i<n;i++){
        scanf("%d %d\n",&x[i],&y[i]);
        if(x[i]>=90&&x[i]<=140&&y[i]>=60&&y[i]<=90){
            t[u]++;
        }
        else{
            u=u+1;
        }
    }
    int max;
    max=0;
    for(int i=0;i<100;i++){
        if(max<=t[i]){
            max=t[i];
        }
    }
    printf("%d",max);
    return 0;
}
int main(){
    int sz[100];
    int cz[100];
    int pz[100];
    int n;
    int a;
    scanf("%d",&n);
    for(int i=0;i<n;i++){
        scanf("%d %d",&cz[i],&sz[i]);
    }
    int sum=0;
    for(int i=0;i<n;i++){
        if(sz[i]>=60&&sz[i]<=90&&cz[i]>=90&&cz[i]<=140){
            sum=sum+1;
            pz[i]=sum;
            }
            else sum=0;
                 pz[i]=sum;
    }
    a=pz[0];
    for(int i=1;i<n;i++){
        if(a<pz[i]){
        a=pz[i];
        }
    }
    printf("%d\n",a);
    return 0;
}
int main()
{
	int n,x,y,h,i,k,e,max;
	scanf("%d",&n);
	h=0;
	max=0;
	if(n<100)
	{
	  for(i=1;i<=n;i++)
	  {
	     scanf("%d%d",&x,&y);
	     if(x<=140&&x>=90&&y>=60&&y<=90&&n!=i)
	       {
		  h+=1;
	       }else if(x>140||x<90||y<60||y>90||n!=i)
	          {
		      if(h>max)
			{
			   max=h;
			}
		      h=0;
		   }else if(n==i)
		      {
			h=h+1;
			if(h>max)
                        {
			   max=h;
			}
		}
	  }printf("%d",max);
	}
	return 0;
}
int main(){
  int n,i,a[99],b[99],pd[99],y=0,j,e,s,max,h[99],x=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){
      pd[i]=1;y=1;
    }else{pd[i]=0;}
  }
  j=0;
  for(s=0;s<n;s++){
    if(pd[s]==1&&pd[s]==pd[s+1]&&(s==0||pd[s-1]==0)){
        e=s+1;x=1;
        while(1){
             if(e==n-1||pd[e+1]==0){break;}
             e++;
        }
    h[j]=e-s+1;
    j++;
    }
  }
 if(y==1&&x==1){
  max=h[0];
  for(i=0;i<j;i++){
    if(max<h[i]){max=h[i];}
  }
  printf("%d",max);}
 else if(y==0){printf("0");}
 else{printf("1");}
  return 0;
}
int main()
{
	int n,i,j,k,s=0,a[101]={0},b[101]={0},c[101]={0},d[101]={0};
	cin>>n;
	for(i=1;i<=n;i++){
		cin>>a[i]>>b[i];
		if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90)
				{if(c[i-1]==0)s++;
		c[i]=s;}
	}
	int sum=0;
	for(i=1;i<=n;i++)
	d[c[i]]++;
	for(i=1;i<=n;i++)
	if(d[i]>sum)sum=d[i];
	cout<<sum;
	return 0;
}
int main(){
	int n,i,j,a[101][2],s=0,b=0;
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		for(j=0;j<2;j++)
		{
		   scanf("%d",&a[i][j]);
		}
	}
	for(i=0;i<n;i++)
	{
		if(a[i][0]>=90&&a[i][0]<=140&&a[i][1]>=60&&a[i][1]<=90)
		{
			s++;
		}
		else
		{
			if(b==0)
			{
				b=s;
			}
			else
			{
				if(s>b)
				{
					b=s;
				}
			}
			s=0;
		}
	}
	if(s>b)
	{
		b=s;
	}
	
		printf("%d",b);


	return 0;
}
int main(){
    int n=0,i=0,j=0,k=0,s=0; //??3???????????0
    cin>>n; //??n
    int a[101],b[101],c[101]; //??????????????????????
    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]???????????
    c[n+1] = 0;
    for(;j<=k;j++){ //????
        if (s<c[j]) s=c[j]; //????????????????????????
    }
    cout<<s; //?????????
    return 0;
}
int main()
{
	int n,i,high[101],low[101],t[101]={0};
	int e,j=0;
	scanf("%d\n",&n);
	for(i=0;i<n;i++)
	{
		scanf("%d%d\n",&high[i],&low[i]);
	}
	for(i=0;i<n;i++)
	{
		if(high[i]<=140&&high[i]>=90&&low[i]<=90&&low[i]>=60)
		{
			t[j]++;
		}else
		{
			j++;
			continue;
			
		}

	}
	int max=t[0];
	for(i=0;i<=j;i++)
	{
		if(t[i]>max)
		{
			e=max;
			max=t[i];
			t[i]=e;
		}
	}
	printf("%d",max);



	return 0;
}
int main() {
	int a[101]={0};
	int high=0,low=0;
	int k=1;
	int z=1;
	int n;
	int max;

	cin >>n;
	for(z=1;z<=n;z++)
	{
		cin >>high>>low;
		if((high<=140)&&(high>=90)&&(low<=90)&&(low>=60)) a[k]++;
		else k++;
	}
	max=a[1];
	for(k=1;k<=100;k++)
		if(a[k]>max) max=a[k];
	cout <<max;
	return 0;
}
int main()
{
	int n=0;
	cin >> n;
	int time=0;
	int max=0;   //???? 
	int i,j=0;
	int a[n],b[n],c[n];
		for(i=0;i<n;i++)
		cin >> a[i] >> b[i];  //????? a?? b?? 
	for(i=0;i<n;i++)
	{
		if(90<=a[i]&&a[i]<=140&&60<=b[i]&&b[i]<=90) c[i]=1;  //???? 
		else c[i]=0;
	}	
	for(i=0;i<n;i++)
	{
        if(c[i]==1) time++;
        else
        {
            if(max<time)
                max=time;
            time=0;
        }
    }
    if(time>max) max=time;
	cout << max <<endl;

return 0;
}
int main()
{
   int n;
   scanf("%d",&n);
   int i=1;
   int x,y,z=0,max;
   max=z;
   while(i<=n){
     scanf("%d %d",&x,&y);
     if(x>=90&&x<=140&&y>=60&&y<=90){
       z=z+1;
        if(z>max){
          max=z;
        }  
     }else if(z==0&&x<90||x>140||y<60||y>90){
       z=0;
     }else if(z!=0&&x<90||x>140||y<60||y>90){
       z=z-1;
     }
       i++;
   }
   printf("%d",max);
   return 0;
}
/**
*@file 6.cpp
*@author ???
*@date 2013-10-24
*@description ????
*/


int main()
{
    int n, high, low, pre, hour;
    cin >> n;
    pre=0;
    hour=0;
    while(n--)
 {
    scanf("%d %d",&high,&low);
    if(high>=90&&high<=140&&low>=60&&low<=90)
    pre++;
    if(!(high>=90&&high<=140&&low>=60&&low<=90))
    pre=0;
    hour=pre>=hour?pre:hour;
 }
    
    cout << hour << endl;
    return 0;
}
/* ????????
 * ?????2012-10-20
 * ???winneshaw
 * ??????????????????
 * ?????90 - 140????????60 - 90???????????????
 * ????????????????????????????????
 */


int main(){
	int n;
	cin>>n;
	int a[100]={0};
	int b[100]={0};
	int istep=0;
	int m=0;
	int i=0;
	do{
		cin>>a[i]>>b[i];
		i++;
	}while(i<n);
	int c[100]={0};
	do
	{if(a[istep]<=140&&a[istep]>=90&&b[istep]<=90&&b[istep]>=60)
		{
	    c[istep]=m+1;
	    m++;
		}
	 else
		 m=0;
	istep++;
	}while(istep<n);
	int e=0;
	int d=0;
	do {
		if(d<c[e])
			d=c[e];
		e++;
	}while(e<n);
	cout<<d<<endl;
	return 0;
}
int main(){
    int n,i,k,max;
    int x[100];
    int y[100];
    int biaoji[100];
    int jilu[100];
    scanf("%d",&n);
    for(i=0;i<n;i++){
      scanf("%d %d",&x[i],&y[i]);
      if(x[i]<141&&x[i]>89&&y[i]<91&&y[i]>59){
        biaoji[i]=1;                                        
      } else{
        biaoji[i]=0;       
      }              
    }
    if(n>1){
      for(i=0;i<100;i++){
      jilu[i]=0;                   
      } 
      k=1;      
      for(i=0;i<n-1;i++){
       if(biaoji[i]==1){
          if(biaoji[i+1]==1){
            k++; 
            jilu[i]=k;                 
          }else{
            k=1;
            jilu[i]=1;
          }            
       }else{
          jilu[i]=0;
          k=1;
       }                
      }
      max=jilu[0];
      for(i=1;i<n;i++){
        if(max<jilu[i]){
            max=jilu[i];                    
        }                
      }
      printf("%d",max); 
      }else{
       printf("%d",biaoji[0]);     
      }
  return 0;    
 }
int main()
{
	int n, j, i, a, b, s, tot;
	cin >> n;
	j=0;
	s=0;
	tot=0;
	for (i=1;i<=n;i++)
	{
		cin >> a;
		cin >> b;
		if (((a>=90)&&(a<=140))&&((b>=60)&&(b<=90)))
		{
			j++;
		    s=j;
		}
		else 
	{   
		if (j<=tot) 
			j=0;
		else
		{
				tot=j;
				j=0;
		}

			
	}
	}
	if (j>=tot)
		tot=j;

	cout << tot;
}
int main(){
int n;
scanf("%d",&n);
int ss[n],sz[n],i=0,zc[n];
for(i=0;i<n;i++)
{
    scanf("%d %d",&(ss[i]),&(sz[i]));
    zc[i]=0;
}
int j=0,zui=0;
for(i=0;i<n;i++)
{
     if((ss[i]>=90)&&(ss[i]<=140)&&(sz[i]<=90)&&(sz[i]>=60))
     {
         zc[j]++;
     }
     else
     {
         j++;
     }
}
for(i=0;i<n;i++)
{
    if(zc[i]>zui)
    {
        zui=zc[i];
    }
}
printf("%d",zui);
return 0;
}
//********************************
//*???????????? **
//*????? 1300012839 **
//*???2013.10.27**
//********************************
int main()
{
	int n,a,b,i,j,k,c[100],d[100],e[100],result;                          //ab??????????c?d????e??j???????
	cin >> n;
	for(i = 0;i <= n-1; i++)
	{
		cin >> a >> b;
		c[i] = a;
		d[i] = b;                                                         //???????c?d??
	}
	for(j = 0;j <= n-1;j++)                                              
		{
			e[j] = 0;
			for( k = j;k <= n-1;k++)                                      //???????j????????
		    {
				if(c[k] >= 90 && c[k] <= 140 && d[k] >= 60 && d[k] <= 90) //????     
					e[j] = e[j] + 1;                                      //????????1
				else break;                                               //?????????????
			}
	    }
	for(j = 0;j < n-1;j++)
		{
			result = e[j]>e[j+1]?e[j]:e[j+1];
			e[j+1] = result;                                             //????n???1.??????????e?????????
	    }
	if(n!=1)cout << result << endl;                                      
	else cout << e[0] << endl;                                            //????????e?0?
	return 0;
}
int main()
{
	int i,n,xy[100][2],m,z=0,k[100];
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		scanf("%d%d",&xy[i][0],&xy[i][1]);
	}
	for(i=0;i<n;i++)
	{
		if((xy[i][0]<=140&&xy[i][0]>=90)&&(xy[i][1]<=90&&xy[i][1]>=60))
		{
			z++;
			k[i]=z;
        }
		else
        {
			z=0;
			k[i]=z;
		}
	}
	int e;
	for(m=1;m<n;m++)
	{
		for(i=0;i<n-m;i++)
		{
			if(k[i]>k[i+1])
			{
				e=k[i+1];
				k[i+1]=k[i];
				k[i]=e;
			}
		}
	}
	printf("%d",k[n-1]);
	
	return 0;
}
int main()
{
	int n,a[100],b[100],z=0,zm=0;
	scanf("%d",&n);
	for(int i=0;i<n;i++)
	{
		scanf("%d%d",&a[i],&b[i]);
		if(a[i]<=140&&a[i]>=90&&b[i]>=60&&b[i]<=90)
		{
			z++;
			if(i==n-1)
			{
				if(z>zm)
				{
				zm=z;
				}
			}
		}else
		{
			if(z>zm)
			{
				zm=z;
			}
			z=0;
		}
	}
	printf("%d",zm);
	return 0;
}
int main()
{
    
    int i,s,n,t;
    s=0;
    t=0;
    scanf("%d",&n);
    struct pulse
    {
           int x;
           int y;
    } a[n];
    for(i=1;i<=n;i++)
    {
                     scanf("%d %d",&a[i].x,&a[i].y);
    }
    for(i=1;i<=n;i++)
    {
                     if(a[i].x<=140&&a[i].x>=90&&a[i].y<=90&&a[i].y>=60)
                     {
                         s++;
                         if(t<s) t=s;
                     }
                     else s=0;
    }
    printf("%d",t);
 
    return 0;
    
}
void main()
{
int a , b , n , i , str[ 120 ] = { 0 } ;
scanf( "%d" , &n );
for( i = 1 ; i <= n ; i ++ )
{
scanf( "%d %d" , &a , &b );
if( a >= 90 && a <= 140 && b >= 60 && b <= 90 )
str[ i ] = 1 ;
}

for( i = 1 ; i <= n ; i ++ )
if( str[ i ] == 1 )
str[ i ] = str[ i - 1 ] + 1 ;

a = 0 ;
for( i = 1 ; i <= n ; i ++ )
if( str[ i ] > a )
a = str[ i ];

printf( "%d\n" , a);
}
int main(){
	int a,b,n,z[100],i,e,r;
	r=0;
	e=-1;
	scanf("%d",&n);
	for(i=0;i<100;i++) z[i]=0;
	for(i=0;i<n;i++){
		scanf("%d%d",&a,&b);
		if(a>=90&&a<=140&&b>=60&&b<=90){z[i]=1;r=1;}
	}
	for(i=e+1;i<n-1;i++){
		if(z[i]==1&&z[i+1]==1){
			for(e=i+1;e<n-1;e++){
				if(z[e]==1&&z[e+1]==1) continue;
				else break;
			}
			if(r<e-i+1) r=e-i+1;
		}
	}
	printf("%d",r);
	return 0;
}
int main()
{
   int n,a[100],b[100],i,c[100],j,d,p,q;
   j=0;
   d=0;
   scanf("%d",&n);
   for(i=0;i<n;i++)
   {
    scanf("%d %d",&(a[i]),&(b[i]));
    if((90<=a[i])&&(a[i]<=140)&&(60<=b[i])&&(b[i])<=90)
	{
           j++;
	}
   else
  {
	 d++;
     c[d]=j;
	 j=0;
   }
  }
   
  if(j!=0)
  {  
	 d++;
	 c[d]=j;
	 int max=0;
	 for(p=1;p<=d;p++)
	 {
	 if(c[p]>max)  
	 {
		 //q=c[d];
		 //c[d]=c[d+1];
		 //c[d+1]=q;
		 max=c[p];
	 }
	 }
  printf("%d",max);
  }
 else
 {int max=0;
     for(p=1;p<=d;p++)
	 {
	   if(c[p]>max)  
	 {
		 //q=c[d];
		 //c[d]=c[d+1];
		 //c[d+1]=q;
		 max=c[p];
	 }
	 }
   printf("%d",max);
 }
 
 return 0;
}
int max(int(x),int(y))
{
    if(x>=y)
        return x;
    else
        return y;
}

int main()
{   int n;
    cin>>n;
    int i=0;
    int t1=0,t2=0;
    int t=0;
    int a,b;
    for (i=0;i<n;i++)
    {
        cin>>a>>b;
        if ((a>=90&&a<=140)&&(b>=60&&b<=90))
       {

        t=t+1;
        t1=t;
       }
        else
       {


        t1=max(t,t2);
        t=0;
        t2=t1;

       }

    }
    t1=max(t,t2);
    cout<<t1;
    return 0;
}
/*
 *    Filename:3.4NormalBloodpressure.cpp
 *
 *  Created on: 2012-10-22
 *      Author: ???
 *    Function:????????????????
 */

int main()
{
	int n,a,b,i=0,h=0;//n??????a?b???????????,i?k?????h???????????
	cin>>n;
	while(n!=0)//??????n??
	{cin>>a >>b;
	if(a>=90 && a<=140 && b>=60 && b<=90)
	   i++;          //?????i+1
	else
	      i=0;     //??????i????
	if(h<=i)
		h=i;         //??h?????????
	   n--;
	  	}
     cout<<h<<endl;
     return 0;
}
int main()
{
	int n,i,k,cs[100]={0},t=0,max;
	int gao[100],di[100];
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		scanf("%d%d",&gao[i],&di[i]);
	}
	for(i=0;i<n;i++)
	{
		if(gao[i]>=90&&gao[i]<=140&&di[i]>=60&&di[i]<=90)
		{
			cs[t]++;
		}
		else
		{
			t++;
		}
	}
	for(i=1;i<t+1;i++)
	{
       for(k=0;k<t+1-i;k++)
	   {
		   if(cs[k]>cs[k+1])
		   {
			   max=cs[k+1];
			   cs[k+1]=cs[k];
			   cs[k]=max;
		   }
	   }
	}
	printf("%d",cs[t]);
	return 0;
}
int main()
{
	int n,p[100][2],i,j,a=0,x=0;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		for(j=0;j<2;j++){
			scanf("%d",&p[i][j]);
		}
	}
	for(i=0;i<n;i++){
		if(p[i][0]>=90&&p[i][0]<=140&&p[i][1]>=60&&p[i][1]<=90){
			a++;
		}
		else{
			if(a>x){
				x=a;
				a=0;
			}
			else{
				a=0;
			}
		}
	}
	if(a>x){
		x=a;
	}
	printf("%d",x);
	return 0;
}
/*
 * NormalBloodPressure.cpp
 *
 *  Created on: 2012-10-16
 *      Author: Cui Zhaoxiong Class4 1200012931
 */
int main(){
	int n=0,m=0;
	int sys[100],dias[100],c[100];
	cin >>n;
	for(int i=0;i<n;i++){
		cin >>sys[i] >>dias[i];
	}
	for (int i=0;i<n;i++){
		c[i]=0;
	}
	for(int i=0;i<n;i++){
		if(90<=sys[i]&&sys[i]<=140&&60<=dias[i]&&dias[i]<=90){	//????????????
			m+=1;
			c[i]=m;
		}
		else {
			c[i]=0;
			m=0;
		}
	}
	m=c[0];
	for (int i=1;i<n;i++){									//?????????
		if (m<c[i]) m=c[i];
	}
	cout <<m;
	return 0;
}
int main(){
	int n;
	scanf("%d",&n);
	int ss[100],sz[100];
	int i,qk[100];
	for(i=0;i<n;i++){
		scanf("%d%d",&ss[i],&sz[i]);
	}
	int e;
	for(e=0;e<n;e++){
		if(ss[e]>=90&&ss[e]<=140&&sz[e]>=60&&sz[e]<=90){
			qk[e]=1;
		}
		else{qk[e]=0;}
	}
	int a=0,c=0;
	int r;
	for(r=0;r<n;r++){
		if(qk[r]==1){
		  int t;
		  for(t=r;qk[t]==1;t++){
			  c++;
		  }
			}
		if(c>a){a=c;}
		c=0;
	}
	printf("%d",a);
	return 0;
}
int main()
{
	int n,i,shousuo[101],shuzhang[101],xiaoshi[101],k=0,t;
scanf("%d",&n);
		for(i=0;i<n;i++){
			scanf("%d%d",&shousuo[i],&shuzhang[i]);
		}
				for(i=0;i<n;i++){
xiaoshi[i]=0;
				}
		for(i=0;i<n;i++){
			if(shousuo[i]<=140&&shousuo[i]>=90&&shuzhang[i]<=90&&shuzhang[i]>=60){
xiaoshi[k]++;
			}else{
k++;
			}
		}
		for(i=0;i<n;i++){
			if(xiaoshi[i]>xiaoshi[0]){
t=xiaoshi[0];
xiaoshi[0]=xiaoshi[i];
xiaoshi[i]=t;
		}
		}
		printf("%d",xiaoshi[0]);
	return 0;
		}
int main()
{
	int n,i,a[100],b[100],n1=0,n2=0;
	scanf("%d",&n);
	for(i=1;i<=n;i++)
	{
		scanf("%d %d",&a[i-1],&b[i-1]);
	    if(a[i-1]>=90 && a[i-1]<=140 && b[i-1]<=90 && b[i-1]>=60)
		{
			n1++;
			if(n1>n2)
			{
				n2=n1;
			}
		}
		else 
			n1=0;
		
	}
	printf("%d\n",n2);
	return 0;
}
int main()
{
    int i,n;
    scanf("%d",&n);
    int shousuo[101],shuzhang[101],count,Max,a[101];
    for(i=0;i<n;i++){
        scanf("%d %d",&shousuo[i],&shuzhang[i]);
        if(shousuo[i]>=90&&shousuo[i]<=140&&60<=shuzhang[i]&&90>=shuzhang[i]){
            a[i+1]=1;
        }else{a[i+1]=0;}
    }
    a[0]=0;
    Max=0;
    count=0;
    for(i=1;i<n+1;i++){
        if(a[i-1]==0&&a[i]==1){
            count=1;
        }else if(a[i-1]==1&&a[i]==1){
            count=count+1;
        }
            if(Max<count){
                Max=count;
            }
        
    }
    printf("%d",Max);
    return 0;
}
int main(){
	int n;
	scanf("%d",&n);
	int sz[100][2];
	int b=0;
	int a=0;
	for(int i=0;i<n;i++){
		for(int k=0;k<2;k++){
		scanf("%d",&sz[i][k]);
		}
		if((sz[i][0]>=90)&&(sz[i][0]<=140)&&(sz[i][1]>=60)&&(sz[i][1]<=90)){
			a=a+1;
			if(a>b){
				b=a;
			}
		}else{
			a=0;
		}

	}
    printf("%d",b);
	

	return 0;
}
int main(){
	int n,i;
	scanf("%d",&n);
	struct press{
		int a,b;
	}press[100];
	for(i=0;i<n;i++){
		scanf("%d%d",&(press[i].a),&(press[i].b));
	}
	int normal=0,max=0;
	for(i=0;i<n;i++){
		if(press[i].a>=90&&press[i].a<=140&&press[i].b>=60&&press[i].b<=90){
			normal++;
		}else{
			if(normal>max){
				max=normal;
			}
			normal=0;
		}
	}
	if(normal>max){
		max=normal;
	}
	printf("%d",max);
	return 0;
}
int main(){
	int n;
	scanf("%d",&n);
	int sz[100][2];
	for(int i=0;i<n;i++){
		scanf("%d",&sz[i][0]);
		scanf("%d",&sz[i][1]);
	}
	int a=0,b=0;
	int sub[100]={0};
	for(int j=0;j<n;j++){
		if(sz[j][0]>=90&&sz[j][0]<=140&&sz[j][1]>=60&&sz[j][1]<=90){
			sub[a]++;
		}
		else
			a++;
	}
	int e;
    for(int k=1;k<a+1;k++){
		for(int m=0;m<a+1-k;m++){
			if(sub[m]<sub[m+1]){
					e =sub[m+1];
					sub[m+1] =sub[m];
					sub[m] = e;
			}
		}
	}
	printf("%d",sub[0]);
    return 0;
}
int main() {
	int n,a,b,c=0,i=0,j=0,m=0;
	int sz[72];
	scanf("%d",&n);
	while(i<n){
		scanf("%d%d",&a,&b);
		if(a<=140&&a>=90&&b<=90&&b>=60){
			j+=1;
		}else{
			sz[m]=j;
			j=0;
			if(c<sz[m]){
				c=sz[m];
			}
			m+=1;
		}
		i+=1;
	}
	if(c<j){
		c=j;
	}
	printf("%d",c);
	return 0;
}
int main(){
	int n,a[100],b[100];
	scanf("%d",&n);
	int i,result=0,p=0;
	for(i=0;i<n;i++){
		scanf("%d%d",&a[i],&b[i]);
	}
	for(i=0;i<n-1;i++){
		if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90){
			p++;
		}else{
			if(p>result){
				result=p;
			}else{
				result=result;
			}
			p=0;
		}
	}
	while(i==n-1){
		if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90){
			p++;
		}
		if(p>result){
			result=p;
		}
		i++;
	}
	printf("%d\n",result);
	return 0;
}