#include <iostream>
using namespace std;

int main(){
	double left,right;
	int a=0,b=0,c=0,d=0;
	int A=0,B=0,C=0,D=0;
	while(cin >> left >> right){
		if(left >= 1.1)
			a++;
		else if(left >= 0.6)
			b++;
		else if(left >= 0.2)
			c++;
		else
			d++;
		if(right >= 1.1)
			A++;
		else if(right >= 0.6)
			B++;
		else if(right >= 0.2)
			C++;
		else
			D++;
	}
	cout << a << " " << A << endl;
	cout << b << " " << B << endl;
	cout << c << " " << C << endl;
	cout << d << " " << D << endl;		
	return 0;
}