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