semeru/Code-Code-CloneDetection-POJ104 huggingface dataset:
int main(){
    int n,count[100]={0},m=0,a,b;
	scanf("%d",&n);
	for(int i=0;i<n;i++){
		scanf("%d %d",&a,&b);
        if((a>=90&&a<=140)&&(b>=60&&b<=90)){
			count[m]++;
		}else{
			m++;
		}
	}
    int e=0,k,f;
	for(k=0;k<n-1;k++){
		for(f=k+1;f<n;f++){
			if(count[f]>count[k]){
				e=count[k];
				count[k]=count[f];
				count[f]=e;
			}
		}
	}
	printf("%d",count[0]);
    return 0;
}
int main(){
	int n,a[101],b[101],i,j=0,c[101],max=0;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d",&a[i],&b[i]);
	}
	for(i=0;i<101;i++){
	c[i]=0;
	}
	for(i=0;i<n;i++){
		if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90){
		c[j]++;
		}else{
			j++;
		}
	}
	for(i=0;i<101;i++){
		if(c[i]>c[max]){
			max=i;
		}
	}
	printf("%d",c[max]);
	return 0;
}
int main(){
	int a,b,c,mid,i,n,high,low,stop;
	a=0;
	b=0;
	c=0;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d",&high,&low);
		if((high>=90)&&(high<=140)&&(low<=90)&&(low>=60)){
			a++;
			c=a;
		}else{
			//if(n==1){
		//		printf("0");
		//	}
			if(a>0){
				mid=b;
				if(a>mid){
					b=a;
				}				
				a=0;
			}
		}
	}
	if(c<b){
		printf("%d",b);
	}else{
		printf("%d",c);
	}
	return 0;
}
int main()
{
  int x,y,z,i,n,a,b,c;
  z=0;
  a=0;
  scanf("%d",&n);
  for(i=1;i<=n;i++)
  {scanf("%d %d",&x,&y);
   if(x>=90&&x<=140&&y>=60&&y<=90)
   z++;
   else z=0;
   if(z>=a) a=z; 
       }
  printf("%d",a);
   return 0;
}
int main()
{
	int n,i,j,l,shou[100],shu[100],total[100]={0},k=0;
  scanf("%d",&n);
  for(i=0;i<n;i++){
     scanf("%d%d",&shou[i],&shu[i]);
  }
  for(j=0;j<n;j++){
	 if(shou[j]>=90&&shou[j]<=140&&shu[j]>=60&&shu[j]<=90){
		 total[k]++;
	  }
     else {
         k++;
	 }
  }	
  int max=0;
  for(l=0;l<k+1;l++){
	  if(total[l]>max){
	    max=total[l];
	  }
  }
  printf("%d",max);
  return 0;
}
main()
{
int n;
scanf("%d", &n);
int a[n], b[n]; int i;
for(i=0; i<n; i++)
   {
   scanf("%d %d", &a[i], &b[i]);
   }
int c[n]; int p=0;
for(i=0; i<n-1; i++)
   {
        if ((a[i]>=90&&a[i]<=140)&&(b[i]>=60&&b[i]<=90))
         {
         p=p+1;
         c[i]=0; 
         }
        else
         {
         c[i]=p; p=0;
         }
   }
if ((a[n-1]>=90&&a[n-1]<=140)&&(b[n-1]>=60&&b[n-1]<=90))
{ c[n-1]=p+1;}
else
{ c[n-1]=p;}
int Max=0;
for(i=0; i<n; i++)
   {
   if (Max<c[i])
   Max=c[i];
   }
printf("%d", Max);
}
int main()
{
	int a[100],b[100];
	int count[100];
	int i,j;
	int n;
	cin>>n;
	for (i=0;i<n;i++)
		count[i]=0;
	for (i=0;i<n;i++)
		cin>>a[i]>>b[i];
	for (i=0;i<n;i++)
	{
		if (a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90)
		{    count[i]=1;
			for (j=i+1;j<n;j++)
			{
				if (a[j]>=90&&a[j]<=140&&b[j]>=60&&b[j]<=90)
					count[i]++;
				else break;
			}
		}
	}
	int max=0;
	for (i=0;i<n;i++)
	{
		if (count[i]>max)
			max=count[i];
	}
	cout<<max<<endl;
	return 0;
}
int main()
{
    int b,t,c,n,i;
    int m=0;
    int a[100];
    scanf("%d",&n);
    for(i=0;i<n;i++){
      scanf("%d %d",&b,&c);
      if(b>=90&&b<=140&&c>=60&&c<=90)
      {
            m++;     
            a[i]=m;
      }      
      else{
           m=0;      
           a[i]=0;
           }
    }
        a[n]=a[n-1];
    for(i=0;i<n;i++)
    {
       if(n==1)
          t=a[0];
       else if(a[i+1]>a[i])
          t=a[i+1];
       else{
          t=a[i+1];
          a[i+1]=a[i];
          a[i]=t;
          t=a[i+1];
          }
    }                                  
    printf("%d",t);
    return 0;
}
int main()
{
	int n,i,j,x,y,max=0,sum[50]={0};
	scanf("%d",&n);
	for(i=j=0;i<n;i++){
		scanf("%d%d",&x,&y);
		if(x>=90&&x<=140&&y>=60&&y<=90)
			sum[j]++;
		else
			if(sum[j])
				j++;
	}
	for(i=0;i<50;i++)
		if(max<=sum[i])
			max=sum[i];
	printf("%d\n",max);
	return 0;
}
/*
 * ????.cpp
 *
 *  Created on: 2012-10-14
 *      Author: ??
 */

int max (int a,int b)    //??????????????????
{
	return a > b?a:b;
}

int main(){
    int n,a,b,ans;    //ans?????
	int sum = 0;
	cin >>n;
	sum = 0;
    ans = 0;
	for (int i = 1;i <= n;i ++)
	{
		cin >>a >>b;
		if ((a >= 90 &&a <= 140) && (b >= 60 &&b <= 90))
			{sum ++;
		ans = max(ans,sum);}    //?????????ans?
		else sum = 0;        //??????????sum??????

	}
	cout <<ans <<endl;
	return 0;
}
int main(){
	int n,i,l,e;
	int k=0;
	int a=0;
	scanf("%d",&n);
	int sz[100][2];
	int sf[100];
	for(i=0;i<n;i++)
	{
		scanf("%d %d",&sz[i][0],&sz[i][1]);
	}
	for(i=0;i<n;i++)
	{
		if(i<n-1)
		{
			if((sz[i][0]>=90)&&(sz[i][0]<=140)&&(sz[i][1]>=60)&&(sz[i][1]<=90))
			{
				a++;
			}
			else
			{
				sf[k]=a;
				k++;
				a=0;
			}
		}
		if(i==n-1)
		{
			if((sz[i][0]>=90)&&(sz[i][0]<=140)&&(sz[i][1]>=60)&&(sz[i][1]<=90))
			{
				sf[k]=a+1;
			}
			else
			{
				sf[k]=a;
			}
		}
	
	}
	for(l=0;l<k;l++)
	{
		if(sf[l]>sf[l+1])
		{
			e=sf[l];
			sf[l]=sf[l+1];
			sf[l+1]=e;
		}
	}
	printf("%d",sf[k]);
	return 0;
}
int main()
{
	int hour[101] ={0}, high, low;
	int n;
	cin >> n;
	int num = 1;
	for(int i = 0; i < n; i++)
	{
		cin >> high >> low;
		if( high >= 90 && high <= 140 && low >= 60 && low <= 90 )
			hour[num] ++;
		else
			num ++;
	}
	int max = 0;
	for(int i = 1; i <= num; i++)
	{
		if( hour[i] > max )
			max = hour[i];
	}
	cout << max << endl;
	return 0;
}
int main(int argc, char* argv[])
{
	int n,plow,phigh,k,i,m;
	scanf("%d",&n);
	for(i=1,k=0,m=0;i<=n;i++){
	scanf("%d %d",&phigh,&plow);
	if((plow>=60)&&(plow<=90)&&(phigh>=90)&&(phigh<=140)){
	k++;}
	else{
		if(k>m){
	m=k;
	k=0;
	}
		else{
	k=0;}
	}}
	if(k>m){
		m=k;}
	printf("%d",m);
	return 0;
}
//***************************
//**???6.cpp
//**??????
//**???2013.10.23
//**?????????
//***************************
//??????????????????????????????
int main()
{
	// n????????a?????????????b?????????????j?k???
	int n, high, low, a[100], b[50], j = 0, k = 0, max = 0;
	cin >> n;

	for (int i = 1; i <= n; i++)
	{
		cin >> high >> low;

		a[i] = (high <= 140 && high >= 90 && low <= 90 && low >= 60);
		if (a[i] == 0) // ??????
		{
			j++; // b????????
			k = 0; // ??????0
		}
		else // ?????
		{
			k++; // ?????1
			b[j] = k;
			if (b[j] > max)
				max = b[j];
		}
	}
	cout << max << endl;
	return 0;
}
//*************************************************
//????????                                *
//??????                                    *
//??10?8?                                     *
//************************************************* 
int main()
{
    //??i?n???????????n 
    //????a?b?c???????????????i????? 
    int i, n, a[100], b[100], c[100] = {0};
    cin >> n;
    //?????
    //????start??????????t?????????max?????????? 
    int start = 0, t = 0, max = 0;
    //???i????c[i]?1 
    for(i = 1; i <= n; i++)
    {
      cin >> a[i] >> b[i];
      if((a[i] >= 90 )&& (a[i] <= 140) && (b[i] >= 60) && (b[i] <= 90))
      c[i] = 1;
    }
    //?????????????? 
    for(i = 1; i <= n+1; i++)
       {
            if(c[i] == 0)
            {
                    t = i - start -1;
                    start = i;
            
            if(max < t)
            max=t;
            }
       }
    cout << max;
    
}
int main(){
	int a[1000],b[1000],n,i=0,t=0,max=0;
	scanf("%d",&n);
	for(i=0;i<n;i=i+1){
		scanf("%d %d",&a[i],&b[i]);
	}
	for(i=0;i<n;i=i+1){
		if(a[i]>=90 && a[i]<=140 && b[i]>=60 && b[i]<=90){
			t=t+1;
			if(t>max){
				max=t;
			}
		}
		else {
            t=0;
			
		}
	}
	printf("%d",max);
	return 0;
}
int main(int argc, char* argv[])
{
    int n,sz[100][2],i,j,p[100]={1},hour=0,hour1[100]={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]<90||sz[i][0]>140||sz[i][1]<60||sz[i][1]>90){
			p[i]=0;
		}
		else p[i]=1;
	}
	for(i=0;i<n;i++){
		if(p[i]==1) hour++;
		if(p[i]==0){
			hour1[i]=hour;
			hour=0;
		}
	}
	for(i=0;i<n;i++){
		if(hour1[i]>hour){
			hour=hour1[i];
		}
	}

		
	    printf("%d",hour);




	
	return 0;
	
}
int main()
{
	int n,x,y,i,t,total,max,a[100],b[100],c[100];
	for(i=0;i<=99;i++)
	{   
		a[i]=0;
		b[i]=0;
		c[i]=0;
	}

	scanf("%d",&n);
	for(i=0,t=0;i<=n-1;i++)
	{
		scanf("%d%d",&x,&y);
		if(x>=90&&x<=140&&y>=60&&y<=90)
		    a[t]=a[t]+1;
		else
		t=t+1;	
	}
max=a[0];
	for(i=0;i<=98;i++)
	{   
        if(max>a[i+1])
			total=max;
		else 
		{
			max=a[i+1];
		     total=max;
		}
	}
printf("%d\n",total);

	
	return 0;
}
int main(){
	int n,i,a[100],b[100],p[100],e[100],j,m=0,max;
	scanf("%d",&n);
	for(i=0;i<n;i++){
	scanf("%d%d",&a[i],&b[i]);
	if((a[i]<=140)&&(a[i]>=90)&&(b[i]<=90)&&(b[i]>=60)){
	    p[i]=1;
	}
	else{
		p[i]=0;
	}
	}
	for(i=0;i<n;i++){
		if(p[i]==1){
			e[m]=0;
			for(j=i;j<n&&p[j]==1;j++){
			e[m]++;
			}
			m++;
		}
	}
	if(m==0)
	e[0]=0;
	max=e[0];
	for(i=1;i<m;i++){
		if(e[i]>max){
		max=e[i];
		}
	}
	printf("%d\n",max);
	


return 0;


}
int main()
{
	int n,j=-1,i,sz[100][2],time[100]={0},f=1,max=0;
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		scanf("%d%d",&sz[i][0],&sz[i][1]);
		if(sz[i][0]>=90&&sz[i][0]<=140&&60<=sz[i][1]&&sz[i][1]<=90&&f==1)
		{
			j++;
			time[j]++;
			f=0;
		}
		else if(sz[i][0]>=90&&sz[i][0]<=140&&60<=sz[i][1]&&sz[i][1]<=90)
		{
			time[j]++;
		}

		else{f=1;}

	}
	for(i=0;i<=j;i++)
	{
		if(max<time[i])
		{
			max=time[i];
		}
	}
	printf("%d",max);
	
	return 0;
}
int main()
{
	int n,i,e;
	int s=0;
	int a=0;
	scanf("%d",&n);
	int **sz=(int**)malloc(sizeof(int*)*n);
	int *sf=(int*)malloc(sizeof(int)*n);
	for(i=0;i<n;i++)
	{
		sz[i]=(int*)malloc(sizeof(int)*2);
		scanf("%d %d",&sz[i][0],&sz[i][1]);
	}
	for(i=0;i<n;i++)
	{
		if(i<n-1)
		{
				if(sz[i][0]>=90&&sz[i][0]<=140&&sz[i][1]>=60&&sz[i][1]<=90)
			{
				s++;
			}
			else
			{
				sf[a]=s;
				a++;
				s=0;
			}
		}
		if(i==n-1)
		{
				if(sz[i][0]>=90&&sz[i][0]<=140&&sz[i][1]>=60&&sz[i][1]<=90)
			{
				s++;
				sf[a]=s;
				a++;
			}
			else
			{
				sf[a]=s;
				a++;
			}
		}

	}
	
	for(i=0;i<a-1;i++)
	{
		if(sf[i]>sf[i+1])
		{
			e=sf[i];
			sf[i]=sf[i+1];
			sf[i+1]=e;
		}
	}
	printf("%d",sf[a-1]);
	return 0;
}
int main(){
	int c,i,a,b,n[100]={0},k=0,j,e;
	scanf("%d",&c);
	for(i=0;i<c;i++){
		scanf("%d%d",&a,&b);
		if((a>=90)&&(a<=140)&&(b>=60)&&(b<=90))
			n[k]+=1;
		else
			k+=1;
	}
	for(j=1;j<=k+1;j++){
	for(i=0;i<k+1-j;i++){

		if(n[i]<n[i+1]){
			e=n[i];
			n[i]=n[i+1];
			n[i+1]=e;
		}
	}
	}
	printf("%d",n[0]);



	return 0;
}
int main(){
    int n,p,i,m,l[100];
    m=0;
    p=0;
    scanf("%d",&n);
    int z[100],q[100];
    for(i=0;i<n;i++){
    scanf("%d %d",&z[i],&q[i]);
    }
    for(i=0;i<100;i++) l[i]=0;
        for(i=0;i<n;i++)
        {
            if(z[i]>=90&&z[i]<=140&&q[i]>=60&&q[i]<=90) {l[m]++;}
            else
            {
              m++;            
            }
        }
    for(i=0;i<=m;i++)
    {
        if(l[i]>p){
           p=l[i]; 
        }
    }
printf("%d",p);
return 0;
}
int main()
{
    int n;
    scanf("%d",&n);
    int sz[n][2];
    int k=0;
    int sum=0;
    for(int i=0;i<n;i++)
    {
        scanf("%d %d",&sz[i][0],&sz[i][1]);
        if(sz[i][0]<=140&&sz[i][0]>=90&&sz[i][1]<=90&&sz[i][1]>=60)
        {
            sum++;
        }
        else 
        {
            if(k<sum)
            {
                k=sum;  
            }
            sum=0;
        }
    }
    if(sum>k)printf("%d",sum);
    else printf("%d",k);
    return 0;
}
/*
 * 1.cpp
 *
 *  Created on: 2012-10-13
 *  Author: ???
 *  Function:????????????????
 */


int highPressure;
int lowPressure;
int a[100];
int hour=0;
int n,j=0;

int main()
{
	cin>>n;//??????
    for(int i=1;i<=n;i++)
    {
    	cin>>highPressure>>lowPressure;
    	if(highPressure>=90&&highPressure<=140&&lowPressure>=60&&lowPressure<=90)//???????
    	{
    		hour++;

    	}
    	else
    		{
    		hour=a[j];//??????????????????????????????????????????
    	    hour=0;
    	    j++;//???????
    		}
    	a[j]=hour;//???????????????????????????????????

    }

    while(j>0)//?????????????????a[0]
        {
    	if(a[j]>a[j-1])
    	{a[j-1]=a[j];}
    	 j--;
        }
    	cout<<a[0];
    	return 0;
}
int main()

{
  int i,j,n,k,a[100],shousuo,shuzhang;
  scanf("%d\n",&n);
  j=0;
  k=0;
  for(i=0;i<n;i++) a[i]=0;
  for(i=1;i<=n;i++)
  {
		scanf("%d%d",&shousuo,&shuzhang);
		if(90<=shousuo&&shousuo<=140)
		{
		   if(60<=shuzhang&&shuzhang<=90)
				a[j]=a[j]+1;
		   else
		   	   j=j+1;
		   

		}
		
		else
		j=j+1;
		
  }
  for(i=0;i<n;i++)
  {
    if(k<a[i]) k=a[i];
  }
  printf("%d\n",k);
}
int main()
{
	int n,i,j[100]={0},s[100][2],l=0,max=0;
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		scanf("%d %d",&s[i][0],&s[i][1]);
	}
	for(i=0;i<n-1;i++)
	{
		if(s[i][0]<=140&&s[i][0]>=90&&s[i][1]<=90&&s[i][1]>=60)
		{
			
			j[l]++;
			if(s[i+1][0]>140||s[i+1][0]<90||s[i+1][1]>90||s[i+1][1]<60)
			{
				l++;
				
			}
		}
	
	}
	if(s[n-2][0]<=140&&s[n-2][0]>=90&&s[n-2][1]<=90&&s[n-2][1]>=60)
	{
		if(s[n-1][0]<=140&&s[n-1][0]>=90&&s[n-1][1]<=90&&s[n-1][1]>=60)
			j[l]++;
	}
	
	else
	{
		if(s[n-1][0]<=140&&s[n-1][0]>=90&&s[n-1][1]<=90&&s[n-1][1]>=60)
			j[l]=1;
	}
	

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

	

	return 0;
}
int main()
{
	int n,a[100][2],i,k=0,t=0;
	scanf("%d",&n);
	for(i=0;i<n;i++)
		scanf("%d%d",&a[i][0],&a[i][1]);
	for(i=0;i<n;i++)
	{
		if(a[i][0]>=90&&a[i][0]<=140&&a[i][1]>=60&&a[i][1]<=90)
			k++;
		else
		{
			t=k>t?k:t;
		    k=0;
		}
	}
	t=k>t?k:t;
	printf("%d\n",t);
	return 0;
}
int main()
{
	int n,i,j;
	int hour[100]={0};
	scanf("%d",&n);
	int data[100][2];
	for(i=0,j=0;i<n;i++)
	{
		scanf("%d%d",&data[i][0],&data[i][1]);
		if(data[i][0]>=90&&data[i][0]<=140&&data[i][1]>=60&&data[i][1]<=90)
			hour[j]++;
		else j++;
	}
	int j0=j;
	int h=0;
	for(j=0;j<=j0;j++)
	{
		if(h<hour[j])h=hour[j];
	}
	printf("%d",h);
	return 0;
}
int main(){
int n,i,j,a[101],b[101],c[101],max,k=0;
scanf("%d",&n);
for(i=0;i<=n;i++){
c[i]=0;
}
for(i=1;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]=1;
}
max=0;
for(i=1;i<=n;i++){
if(c[i]==1&&c[i-1]==1)k=k+1;
else k=0;
if(k>max)max=k;

}
if (max==0)
for(i=1;i<=n;i++)
if(c[i]==1){
	printf("1");
	return 0;


}
if(max!=0)
printf("%d",max+1);
if(max==0) printf("%d",max);
return 0;
}
int main(){
	int n;

	scanf("%d\n",&n);
	int sz[100][100];
	int jg[100]={0};
	for(int i=0;i<n;i++){
		scanf("%d %d",&sz[i][0],&sz[i][1]);
	}
	
	int t=0;
	int p=0;
	
	for(int k=0;k<=n;k++){
		if((sz[k][0]<=140)&&(sz[k][0]>=90)&&(sz[k][1]>=60)&&(sz[k][1]<=90)){
			jg[t]++;
		}else{
			t+=2;
		}
	}
	for(int q=0;q<(t+1);q++){
		int e;
		if(jg[q]>jg[q+1]){
			e=jg[q];
			jg[q+1]=jg[q];
			e=jg[q];
		}
	}
	
	printf("%d",jg[t+1]);
return 0;
}
int main (){
	int i,j,t=0,max=0,n;
	int xy[100][2];
	scanf("%d",&n);
	for (i=0;i<n;i++){
		for (j=0;j<2;j++){
			scanf ("%d",&xy[i][j]);
		}
	}
	for (j=0;j<n;j++){
		if (xy[j][0]>=90&&xy[j][0]<=140&&xy[j][1]>=60&&xy[j][1]<=90){
			t=t+1;
			for (i=j+1;i<n;i++){
                  if (xy[i][0]>=90&&xy[i][0]<=140&&xy[i][1]>=60&&xy[i][1]<=90){
					  t++;
				  }
				  else break;
			}
			if (t>max)  max=t;
			
		}
		t=0;
	}
	printf ("%d",max);
	return  0;
}
int main(){
	int i,n,t,j,max,e,f;
    t=0;
	scanf("%d",&n);
	int a[100];int b[100];int c[100];
    for(j=0;j<=99;j++)
		a[j]=0,b[j]=0,c[j]=0;
	max=0;
	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){
			t++;
		}else{c[i]=t;
	t=0;
	}
	c[n]=t;
	}
	for(i=0;i<=n;i++){
		if(c[i]>max){max=c[i];}
	}
	printf("%d",max);
	return 0;
}
int main(){
	int n,i,m,k;
	int gy[100];
	int dy[100];
	k=0;
	m=0;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d",&gy[i],&dy[i]);
		if(gy[i]>=90&&gy[i]<=140&&dy[i]>=60&&dy[i]<=90){
			k++;if(k>m){
				m=k;
			}}else{
				m=m;
				k=0;
		}
	}
	printf("%d",m);
	return 0;
}
int n,high,low,s,ans;//n?????high,low????????????????,s??????????????ans???
int main()
{
  cin>>n;//??
  for(;n--;)//??n?
  {
    cin>>high>>low;//????????????????
    if(90<=high&&high<=140&&60<=low&&low<=90)//??
    {
      ++s;//?????????
      if(s>ans)//????
        ans=s;
    }
    else//???
      s=0;//?????????
  }
  cout<<ans<<endl;//??
  return 0;
}
/*
 *????????.cpp
 *?????
 *????: 2012-10-20
 *?????????????????????90 - 140????????60 - 90????????????????????????????????????????????????
 */


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

	   else{
		b[i]=k;
		k=0;
	   }
	}
		
	max=0;
	for(i=0;i<n;i++){
		if(max<b[i]){
		    max=b[i];
		}
	}
	printf("%d",max);
	return 0;
}
//***************************************
//*?????(5-6) ????            **
//*?????? 1200012945             **
//*???2012.10.12                    **
//***************************************

int main()          
{                      

	int i, n, a[100]={0}, b[100]={0}, x, h;
	cin >> n;
	x = 0;
	h = 0;
	for (i=1; i<=n; i++)
	{
		cin >> a[i] >> b[i];
		if (a[i] <= 140 && a[i] >=90 && b[i] <=90 && b[i] >=60)
			x = x + 1;
		else if (x >= h)
		{
			h = x;
			x = 0;
		}
		else x = 0;
	}
	if (x >= h)
		h = x;
	cout << h << endl;
	return 0;                        

}
int t[10001];
int main()
{
   int i,n,m=0,t=0,x,y;
   scanf("%d",&n);
    for(i=0;i<n;i++)
{
    scanf("%d%d",&x,&y);
    if(x>=90&&x<=140&&y<=90&&y>=60){t++;m=m>t?m:t;}
    else t=0;
}
    printf("%d",m);
    return 0;
}
int main(){
	int n;
	int shifou[100];
	int a,b;
	int shijian[100];
	int i,j=0;
	int k;
	for(i=0;i<100;i++){
		shijian[i]=0;
	}
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d%d",&a,&b);
		if(a>=90&&a<=140&&b>=60&&b<=90){
			shifou[i]=1;
		}
		else{
			shifou[i]=0;
		}
	}
	for(i=0;i<n;i++){
		if(shifou[i]==1){
			shijian[j]+=1;
		}else{
			j++;
		}
	}
	k=j+1;
	int e;
	for(j=1;j<k;j++){
		for(i=0;i<k-j;i++){
			if(shijian[i]<shijian[i+1]){
				e=shijian[i];
				shijian[i]=shijian[i+1];
				shijian[i+1]=e;
			}
		}
	}
	printf("%d",shijian[0]);
	return 0;
}
int main() {
	int n,i,j,k=0,m=0,a[100],b[100],c[100],max=0;
	cin>>n;
	for(i=0;i<n;i++)
		cin>>b[i]>>c[i];
	for(i=0;i<n;i=j+1){
		for(j=i,m=0;j<n&&b[j]>=90&&b[j]<=140&&c[j]>=60&&c[j]<=90;j++,m++);
	a[k++]=m;
	}
	for(i=0;i<k;i++){
		if(a[i]>=max)
		   max=a[i];}
	cout << max << endl;
	return 0;
}
int main()
{
    int n,i,j=0,max;
    int bp[N][2];
    int sz[N];
    int hou[N];
    scanf("%d",&n);
    for(i=0;i<=n-1;i++)
    {
        scanf("%d%d",&bp[i][0],&bp[i][1]);
    }
    for(i=0;i<=n;i++)
    {
        sz[i]=0;
        hou[i]=0;
    }
    for(i=0;i<=n-1;i++)
    {
        if(((bp[i][0]>=90)&&(bp[i][0]<=140))&&((bp[i][1]>=60)&&(bp[i][1]<=90)))
        {
          sz[i]=1;
        }
    
    }
    for(i=0;i<=n;i++)
    {
        if(sz[i]==1)
        {
           j++; 
        }
        else
        {
            hou[i]=j;
            j=0;
        }
    }
    max=hou[0];
    for(i=0;i<=n;i++)
    {
        if(max<hou[i])
        {
            max=hou[i];
        }
    }
    printf("%d",max);
    return 0;   
}
int main()
{
	int n, a, b, i, k=0,m=0;
	cin >> n;

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

		if (a >= 90 && a <= 140 && b >=60 && b <=90)
		{
			k+=1;
		}
		else
		{
			m=(m > k) ? m : k ;
			k=0;
		}
	}
	m=(m > k) ? m : k ;
	cout << m << endl;

	return 0;
}
int main(){
int n,m1,m2;
int a=1;
int b=0;
int c=0;
scanf("%d",&n);
while(a<=n){
	scanf("%d%d",&m1,&m2);
	if(m1>=90&&m1<=140&&m2>=60&&m2<=90){
		b=b+1;
	}else{
		if(b>=c){
			c=b;
		}
			b=0;
	}
	a=a+1;
}
if(b>=c){
	c=b;
}
   printf("%d",c);
   return 0;}
void main(){
	int n,x,y,i,hour[100];
	int normal[100],m=0;
	scanf("%d",&n);
	for(i=0;i<100;i++)
		normal[i]=0;
	for(i=0;i<n;i++){
		scanf("%d%d",&x,&y);
		if(x<90||x>140||y<60||y>90)
			m++;
		else
			normal[m]++;
	}
	for(i=0;i<=m;i++){
		if(normal[i]<normal[i-1])
			normal[i]=normal[i-1];
	}
	printf("%d",normal[i-1]);
}
int main()
{
	int n,a[300],b[300],c[300],t,x,m=0,i,j=0;
	scanf("%d",&n);
	if(n<=100){
		for(i=0;i<n;i=i+1)
		scanf("%d %d",&a[i],&b[i]);
		for(i=0;i<n;i=i+1){
			if(a[i]>=90&&a[i]<=140&&b[i]>=60&&b[i]<=90){
				m=m+1;if(i==n-1)c[j]=m;
			}
			else {c[j]=m;m=0;j=j+1;}
		
		}
		x=c[0];
		for(t=0;t<j+1;t++){
			if(x<c[t]) x=c[t];
		}
		printf("%d\n",x);
	}
	return 0;
}
int main()
{
	int a,b,c=0,e,n,i,k;
	int sz[100]={0};
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		scanf("%d%d",&a,&b);
		if(a>=90&&a<=140&&b>=60&&b<=90)
		{
	sz[c]++;
		}
		else
		{
		c++;
		}
	}
	for(i=0;i<99;i++)
	{
		for(k=0;k<99-i;k++)
		{
			if(sz[k]>sz[k+1])
			{
				e=sz[k];
				sz[k]=sz[k+1];
				sz[k+1]=e;
			}
		}
	}
	printf("%d",sz[99]);


	return 0;
}
int main()
{
	int i,n,a,b,x=0,hour=0;
	cin>>n;
	for(i=1;i<=n;i++)
	{
		cin>>a>>b;
		if(a>=90&&a<=140&&b>=60&&b<=90)
		{x=x+1;
		if(x>hour)
			hour=x;}
		     else x=0;
	}
	cout<<hour<<endl;
	return 0;
}
int main(){
	int n;
	cin>>n;
	int count,max=0,i=0;
	while(i<n){
		count=0;
		int h,l;
		for(int j=i;j<n;j++){
			cin>>h>>l;
			if((h>140||h<90)||(l>90||l<60)){
				i++;
				break;
			}
			else{
				count++;
				if(count>max) max=count;
				i++;
			}
		}
	}
	cout<<max;
	return 0;
}
void main()
{
	int n,max=0;
	int c[100]={0};
	int i,j=0;
	int sum[100]={0};
	int a[100],b[100];
	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[i]=1;
	}
	for(i=0;i<n;i++)
	{
		if(c[i]==1)
		{
			if(i==0||(i>0&&c[i-1]==1))
				sum[j]++;
			else 
			{
				j++;
				sum[j]++;
			}
		}
	}
	for(i=0;i<=j;i++)
		if(max<sum[i])max=sum[i];
	printf("%d",max);

		

}
int main() 
{int m=0,k; 
int i,n,j; 
scanf("%d",&n);
j=n;
int sz[j],ss[j]; 
for(i=0;i<j;i++){
	scanf("%d %d",&sz[i],&ss[i]);
}
for(i=0;i<n;i++){
	if(sz[i]>=90&&sz[i]<=140&&ss[i]>=60&&ss[i]<=90){
		m++;}
	else { k=(k>=m)?k:m;
	m=0;
}}
	k=(k>=m)?k:m;

printf("%d",k);
return 0;
}
int main(){
    int n,i,t,j;
    scanf("%d",&n);
    int a[100][2],b[100];
    for(i=0;i<n;i++){
        scanf("%d%d",&a[i][0],&a[i][1]);
    }
    j=0;
    b[j]=0;
    for(i=0;i<n;i++){
        if(a[i][0]<=140&&a[i][0]>=90&&a[i][1]<=90&&a[i][1]>=60){
            b[j]=b[j]+1;
        }else{
            j++;
            b[j]=0;
        }
    }

        t=b[0];
    for(i=0;i<j;i++){
    t=(t>b[i+1]?t:b[i+1]);
    }

 printf("%d\n",t);
    return 0;
}
int main()
{
 int n,a,b,i,j,k;
 scanf("%d",&n);
 j=0;
 k=0;
 for(i=0;i<n;i++)
 {
  scanf("%d %d",&a,&b);
  if(a>=90&&a<=140)
   {
    if(b>=60&&b<=90)
     {j=j+1;
       if(j>=k)
       k=j;
     }
    else j=0;
   }
   else j=0;
  }
 printf("%d",k);
 return 0;
}
int main(){
	int n;
	scanf("%d",&n);
	struct point{
		int a,b;
	}
	sz[100];
	int i;
	for(i=0;i<n;i++){
		scanf("%d%d",&sz[i].a,&sz[i].b);
	}
	int xsz[100]={0};
	int j;
	for(i=0;i<n;i++){
		if(sz[i].a>=90&&sz[i].a<=140&&sz[i].b>=60&&sz[i].b<=90){
			xsz[i]+=1;
			for(j=i+1;j<n;j++){
				if(sz[j].a>=90&&sz[j].a<=140&&sz[j].b>=60&&sz[j].b<=90){
					xsz[i]+=1;
				}else{
					break;
				}
			}
		}
	}
	int max=0;
	for(i=0;i<n;i++){
		if(xsz[i]>max){
			max=xsz[i];
		}
	}
	printf("%d\n",max);
	return 0;
}
int main()
{
	int n,m=0,i,j,max[100],p[100][2];
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d",&p[i][0],&p[i][1]);
	}
	for(i=0;i<100;i++){
		max[i]=0;
	}
	for(i=0;i<n;i++){
		if(p[i][0]>=90&&p[i][0]<=140&&p[i][1]>=60&&p[i][1]<=90){
			max[i]=max[i-1]+1;
		}
	}
	for(j=0;j<100;j++){
		if(max[j]>m){
			m=max[j];
		}
	}
	printf("%d\n",m);
	return 0;
}
int main(){
	int n,i,j=1,xy[100][2],zc[100],k,max;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d %d",&xy[i][1],&xy[i][2]);
	}
	zc[1]=0;
	for(i=0;i<n;i++){
		if(xy[i][1]>=90&&xy[i][1]<=140&&xy[i][2]>=60&&xy[i][2]<=90){
          zc[j]++;
		}else{
	      j++;
		  zc[j]=0;
		}
	}
	
	max=zc[1];
	for(k=2;k<=j;k++){
		if(max<zc[k])
			max=zc[k];
	}
	printf("%d",max);

	return 0;
}