#include <bits/stdc++.h>

using namespace std;

int main(){
    double l,r;
    vector<pair<int,int>> ans(4,make_pair(0,0));
    while(true){
        cin>>l>>r;
        if(cin.fail())break;
        if(l>=1.1)ans[0].first++;
        else if(l>=0.6)ans[1].first++;
        else if(l>=0.2)ans[2].first++;
        else ans[3].first++;

        if(r>=1.1)ans[0].second++;
        else if(r>=0.6)ans[1].second++;
        else if(r>=0.2)ans[2].second++;
        else ans[3].second++;
    }
    for(auto i:ans)cout<<i.first<<" "<<i.second<<endl;
    return 0;
}
