#include<iostream>
#include<string>
#include<algorithm>	
#include<cmath>
#include<map>
#include<vector>
#define int long long
using namespace std;
int test[51];
signed main() {
    double n, m; int a = 0, b = 0, c = 0;
    int d = 0, e = 0, f = 0, g = 0, h = 0;
    while (cin >> n >> m) {
        if (n >= 1.1) { a++; }
        else if (n >= 0.6) { b++; }
        else if (n >= 0.2) { c++; }
        else { d++; }
        if (m >= 1.1) { e++; }
        else if (m >= 0.6) { f++; }
        else if (m >= 0.2) { g++; }
        else { h++; }
    }
    cout << a << ' ' << e << endl;
    cout << b << ' ' << f << endl;
    cout << c << ' ' << g << endl;
    cout << d << ' ' << h << endl;
}
