#include <bits/stdc++.h>
int abs(int n) {
  if (n < 0) return -n;
  return n;
}
int main() {
  int a, b;
  scanf("%d %d", &a, &b);
  int w1 = 0, draw = 0, w2 = 0;
  for (int x = 1; x <= 6; x++) {
    if (abs(a - x) < abs(b - x))
      w1++;
    else if (abs(a - x) > abs(b - x))
      w2++;
    else
      draw++;
  }
  printf("%d %d %d", w1, draw, w2);
}
