#include<iostream>
using namespace std;

int main(){
  double left,light;
  int ans_left[4]={0},ans_light[4]={0};
  while(cin >> left){
    cin >> light;
    if(left >= 1.1) ans_left[0]++;
    else if(left >= 0.6) ans_left[1]++;
    else if(left >= 0.2) ans_left[2]++;
    else ans_left[3]++;
    if(light >= 1.1) ans_light[0]++;
    else if(light >= 0.6) ans_light[1]++;
    else if(light >= 0.2) ans_light[2]++;
    else ans_light[3]++;
  }
  for(int i=0;i<4;i++){
    cout << ans_left[i] << " " << ans_light[i] << endl;
  }
}