#include <iostream>
#include <complex>
#include <sstream>
#include <string>
#include <algorithm>
#include <deque>
#include <list>
#include <map>
#include <numeric>
#include <queue>
#include <vector>
#include <set>
#include <limits>
#include <cstdio>
#include <cctype>
#include <cmath>
#include <cstring>
#include <cstdlib>
#include <ctime>
using namespace std;
#define REP(i, j) for(int i = 0; i < (int)(j); ++i)
#define FOR(i, j, k) for(int i = (int)(j); i < (int)(k); ++i)
#define SORT(v) sort((v).begin(), (v).end())
#define REVERSE(v) reverse((v).begin(), (v).end())
typedef complex<double> P;
const int T = 4;
const int E = 2;

int check(double d){
  if(d >= 1.1) return 0;
  else if(d >= 0.6) return 1;
  else if(d >= 0.2) return 2;
  return 3;
}

int main() {
  int ans[T][E];
  REP(i, T) REP(j, E) ans[i][j] = 0;
  double r, l;
  while(scanf("%lf %lf", &l, &r) != EOF){
    ++ans[check(l)][0];
    ++ans[check(r)][1];
  }
  REP(i, T) cout <<ans[i][0] <<" " <<ans[i][1] <<endl;
  return 0;
}