#include <iostream>
#include <vector>
#include <map>
#include <cstring>
#include <string>
#include <stack>
#include <queue>
#include <cmath>
#include <cstdlib>
#include <cstdio>
#include <algorithm>
#include <sstream>
using namespace std;

#define rep(i,n) for(int i=0;i<(int)n;i++)
#define repp(i,k,n) for(int i=k;i<(int)n;i++)
#define rei(n) for(int i=0;i<(int)n;i++)
#define rel(n) for(int l=0;l<(int)n;l++)
#define al(s) s.begin(),s.end()

typedef pair<int, int> pi;
typedef pair<pi, pi> ppi;
typedef pair<int, ppi> pipp;
int a(double w)
{
	if (w >= 1.1)return 0;
	if (w >= 0.6)return 1;
	if (w >= 0.2)return 2;
	return 3;
}

int main()
{
	int R[4] = {};
	int L[4] = {};
	double r, l;
	while (cin >> r >> l)
	{
		R[a(r)]++;
		L[a(l)]++;
	}
	rei(4)
	{
		cout << R[i] << " " << L[i] << endl;
	}
}