#include<iostream>
using namespace std;
int main(void){
    int l[4],r[4];
    double left,right;
    for(int i=0;i<4;i++){
        l[i] = 0;
        r[i] = 0;
    }
    while(cin >> left >> right){
        if(left>=1.1)       l[0]++;
        else if(left>=0.6)  l[1]++;
        else if(left>=0.2)  l[2]++;
        else                l[3]++;
        if(right>=1.1)      r[0]++;
        else if(right>=0.6) r[1]++;
        else if(right>=0.2) r[2]++;
        else                r[3]++;
    }
    for(int i=0;i<4;i++)    cout << l[i] << " " << r[i] << endl;
}
