#include <cstdio>


using namespace std;

static int Al,Ar,Bl,Br,Cl,Cr,Dl,Dr;

int main(){

    float l,r;
    while (scanf("%f%f",&l,&r)!=EOF){
        if (l<0.2)
            Dl++;
        else if (l<0.6)
            Cl++;
        else if (l<1.1)
            Bl++;
        else 
            Al++;


        if (r<0.2)
            Dr++;
        else if (r<0.6)
            Cr++;
        else if (r<1.1)
            Br++;
        else 
            Ar++;
    }

    printf("%d %d\n%d %d\n%d %d\n%d %d\n",Al,Ar,Bl,Br,Cl,Cr,Dl,Dr);

    return 0;
}
