#include <iostream>
using namespace std;
int main()
{
	int e[8] = {0}, i;
	double l, r;
	while (cin >> l)
	{
		if (cin.eof()) break;
		cin >> r;
		if (l >= 1.1)		e[0]++;
		else if (l >= 0.6)	e[2]++;
		else if (l >= 0.2)	e[4]++;
		else				e[6]++;
		if (r >= 1.1)		e[1]++;
		else if (r >= 0.6)	e[3]++;
		else if (r >= 0.2)	e[5]++;
		else				e[7]++;
	}
	for (i = 0; i < 4; i++)
	{
		cout << e[i*2] << " " << e[i*2+1] << endl;
	}
}