#include<iostream>
#include<cstring>
using namespace std;

int main(void){
	int l[4],r[4];
	memset(l,0,sizeof(l));
	memset(r,0,sizeof(r));
	double a,b;
	while(~scanf("%lf%lf",&a,&b)){
		if(a>=1.1)l[0]++;
		else if(a>=0.6)l[1]++;
		else if(a>=0.2)l[2]++;
		else l[3]++;
		if(b>=1.1)r[0]++;
		else if(b>=0.6)r[1]++;
		else if(b>=0.2)r[2]++;
		else r[3]++;
	}
	for(int i=0;i<=3;i++){
		printf("%d %d\n",l[i],r[i]);
	}
    return 0;
}