#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b;
  cin >> a >> b;
  int a_wins = 0, b_wins = 0, draw = 0;
  for (int i = 1; i <= 6; i++) {
    int diff_a = abs(a - i);
    int diff_b = abs(b - i);
    if (diff_a == diff_b) {
      draw++;
    } else if (diff_a < diff_b) {
      a_wins++;
    } else {
      b_wins++;
    }
  }
  printf("%d %d %d", a_wins, draw, b_wins);
  return 0;
}
