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

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