#include<cstdio>
#include<algorithm>
#include<iostream>
using namespace std;
int main()
{
    double a,b;
    int a1=0,a2=0,b1=0,b2=0,c1=0,c2=0,d1=0,d2=0;
    while(cin>>a>>b)
    {
        if(a<0.2)d1++;
        else if(0.2<=a&&a<0.6)c1++;
        else if(0.6<=a&&a<1.1)b1++;
        else if(1.1<=a)a1++;
        if(b<0.2)d2++;
        else if(0.2<=b&&b<0.6)c2++;
        else if(0.6<=b&&b<1.1)b2++;
        else if(1.1<=b)a2++;
    }
    cout<<a1<<" "<<a2<<endl;
    cout<<b1<<" "<<b2<<endl;
    cout<<c1<<" "<<c2<<endl;
    cout<<d1<<" "<<d2<<endl;
    return 0;
}