#include <bits/stdc++.h>
using namespace std;
char arr[100][100];
int main(void) {
  int a, b, aa = 0, bb = 0, draw = 0;
  cin >> a >> b;
  for (int i = 1; i <= 6; i++) {
    if (abs(i - a) < abs(i - b))
      aa++;
    else if (abs(i - a) > abs(i - b))
      bb++;
    else if (abs(i - a) == abs(i - b))
      draw++;
  }
  cout << aa << " " << draw << " " << bb;
  return 0;
}
