#include<iostream>
#include<vector>

#define rep(i,n) for(int i = 0;i < n ; ++i)

using namespace std;

using ll = long long;

int cntl[4], cntr[4];
int main(){
    double l, r;
    
    while(cin>>l>>r){
        if(l>=1.09)cntl[0]++;
        else if(l>=0.59)cntl[1]++;
        else if(l>=0.19)cntl[2]++;
        else cntl[3]++;

        if(r>=1.09)cntr[0]++;
        else if(r>=0.59)cntr[1]++;
        else if(r>=0.19)cntr[2]++;
        else cntr[3]++;
    }
    rep(i,4){
        cout<<cntl[i]<<" "<<cntr[i]<<endl;
    }
}
