#include <iostream>
#include <algorithm>
using namespace std;
int main(void){
    
    double a,b;
    int c=0,d=0,e=0,f=0;
    int g=0,h=0,i=0,j=0;
    
    while(cin >>a>>b){
        if(a>=1.1) c+=1;
        else if(a>=0.6 && a<1.1) d+=1;
        else if(a>=0.2 && a<0.6) e+=1;
        else f+=1;
        
        if(b>=1.1) g+=1;
        else if(b>=0.6 && b<1.1) h+=1;
        else if(b>=0.2 && b<0.6) i+=1;
        else j+=1;
    }
    
    cout <<c<<" "<<g<<endl;
    cout <<d<<" "<<h<<endl;
    cout <<e<<" "<<i<<endl;
    cout <<f<<" "<<j<<endl;
}

