#include <bits/stdc++.h>
using namespace std;
int mod(int x) {
  if (x < 0) x = -x;
  return x;
}
int main() {
  int i, j, k, l, m, n, sum = 0;
  int a, b;
  cin >> a >> b;
  int win1 = 0, draw = 0, win2 = 0;
  for (i = 1; i <= 6; i++) {
    if (mod(a - i) < mod(b - i))
      win1++;
    else if (mod(a - i) == mod(b - i))
      draw++;
    else
      win2++;
  }
  cout << win1 << " " << draw << " " << win2;
}
