#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c, d, cnt1 = 0, cnt2 = 0, cnt3 = 0, i;
  cin >> a >> b;
  for (i = 1; i <= 6; i++) {
    c = a - i;
    d = b - i;
    if (c < 0) c = -c;
    if (d < 0) d = -d;
    if (c < d)
      cnt1++;
    else if (c == d)
      cnt2++;
    else
      cnt3++;
  }
  cout << cnt1 << " " << cnt2 << " " << cnt3 << endl;
}
