#include<bits/stdc++.h>
using namespace std;

int main()
{
  double N,M;
  int l_A = 0; int l_B = 0; int l_C = 0; int l_D = 0;
  int r_A = 0; int r_B = 0; int r_C = 0; int r_D = 0;

  while(cin>>N>>M){

    if(N >= 1.1){
      ++l_A;
    }
    else if(N < 1.1 && N >= 0.6){
      ++l_B;
    }
    else if(N < 0.6 && N >= 0.2){
      ++l_C;
    }
    else{
      ++l_D;
    }

    if(M >= 1.1){
      ++r_A;
    }
    else if(M < 1.1 && M >= 0.6){
      ++r_B;
    }
    else if(M < 0.6 && M >= 0.2){
      ++r_C;
    }
    else{
      ++r_D;
    }
  }

  cout<<l_A<<" "<<r_A<<endl;
  cout<<l_B<<" "<<r_B<<endl;
  cout<<l_C<<" "<<r_C<<endl;
  cout<<l_D<<" "<<r_D<<endl;

  return 0;
}
