#include <iostream>
using namespace std;
int main(){
  double l,r;
  double ll[4] = {0},rr[4]= {0};
  while( cin >> l >> r){

    if(l >= 1.1 )ll[0]++;
    else if(l >= 0.6 )ll[1]++;
    else if(l >= 0.2 )ll[2]++;
    else ll[3]++;
    if(r >= 1.1 )rr[0]++;
    else if(r >= 0.6 )rr[1]++;
    else if(r >= 0.2 )rr[2]++;
    else rr[3]++;
  }
  for(int i = 0 ; i < 4 ; i++){
    cout << ll[i] <<" " << rr[i] << endl;
  }
  return 0;
}