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