#include <stdio.h>

int main()
{
  double m,n;

  int aleft=0,aright=0,bleft=0,bright=0;
  int cleft=0,cright=0,dleft=0,dright=0;


  while( scanf("%lf %lf",&m,&n) != EOF ){
    if(m>=1.1){
      aleft++;
    }else if(m>=0.6){
      bleft++;
    }else if(m>=0.2){
      cleft++;
    }else{
      dleft++;
    }
    if(n>=1.1){
      aright++;
    }else if(n>=0.6){
      bright++;
    }else if(n>=0.2){
      cright++;
    }else{
      dright++;
    }
  }

  printf("%d %d\n",aleft, aright);
  printf("%d %d\n",bleft, bright);
  printf("%d %d\n",cleft, cright);
  printf("%d %d\n",dleft, dright);
}