#include <bits/stdc++.h>
int main() {
  int a, b, s = 0, t = 0, r = 0, i, c, d;
  scanf("%d %d", &a, &b);
  for (i = 1; i <= 6; i++) {
    c = abs(a - i);
    d = abs(b - i);
    if (c < d)
      s++;
    else if (c > d)
      t++;
    else
      r++;
  }
  printf("%d %d %d\n", s, r, t);
  return 0;
}
