#include <bits/stdc++.h>
using namespace std;
int a, b, c1, c2, c3;
int main() {
  cin >> a >> b;
  for (int i = 1; i < 7; i++) {
    if (abs(a - i) < abs(i - b))
      c1++;
    else if (abs(a - i) == abs(i - b))
      c2++;
    else
      c3++;
  }
  cout << c1 << " " << c2 << " " << c3 << endl;
  return 0;
}
