#include <stdio.h>
#include <iostream>

using namespace std;

void check(double c, int k[][2], int d) {
	if (c >= 1.1) {
		k[0][d]++;
	} else if (c >= 0.6) {
		k[1][d]++;
	} else if (c >= 0.2) {
		k[2][d]++;
	} else {
		k[3][d]++;
	}
	return;
}

int main() {
	double a,b;
	int hyou[4][2] = {0};

	while (cin >> a >> b) {
		check(a,hyou,0);
		check(b,hyou,1);
	}

	for (int i = 0; i < 4; i++) {
		cout << hyou[i][0] << " " << hyou[i][1] << endl;
	}
	return 0;
}