#include <cstdio>

int main(){
	double l, r;
	int lA, lB, lC, lD;
	int rA, rB, rC, rD;
	
	lA = lB = lC = lD = 0;
	rA = rB = rC = rD = 0;
	
	while(scanf("%lf %lf", &l, &r) != EOF){
		if(l >= 1.1){
			lA++;
		}else if(l >= 0.6){
			lB++;
		}else if(l >= 0.2){
			lC++;
		}else {
			lD++;
		}
		if(r >= 1.1){
			rA++;
		}else if(r >= 0.6){
			rB++;
		}else if(r >= 0.2){
			rC++;
		}else {
			rD++;
		}
	}
	
	printf("%d %d\n%d %d\n%d %d\n%d %d\n", lA, rA, lB, rB, lC, rC, lD, rD);
	
	return 0;
}
	