#include <bits/stdc++.h>
using namespace std;
int checkRight(int a, int b, int c, int d, int e, int f) {
  if ((a == c && c == e) || (b == d && d == f) || (a == c && b == d) ||
      (c == e && d == f))
    return 0;
  int x1, y1, z1;
  x1 = ((a - c) * (a - c) + (b - d) * (b - d));
  y1 = ((c - e) * (c - e) + (d - f) * (d - f));
  z1 = ((a - e) * (a - e) + (b - f) * (b - f));
  if ((x1 == (y1 + z1)) || (y1 == (x1 + z1)) || (z1 == (x1 + y1))) return 1;
  return 0;
}
int main() {
  int a, b, c, d, e, f;
  cin >> a >> b >> c >> d >> e >> f;
  if (checkRight(a, b, c, d, e, f))
    cout << "RIGHT";
  else {
    int x = (checkRight(a + 1, b, c, d, e, f)) +
            (checkRight(a - 1, b, c, d, e, f)) +
            (checkRight(a, b + 1, c, d, e, f)) +
            (checkRight(a, b - 1, c, d, e, f)) +
            (checkRight(a, b, c + 1, d, e, f)) +
            (checkRight(a, b, c - 1, d, e, f)) +
            (checkRight(a, b, c, d + 1, e, f)) +
            (checkRight(a, b, c, d - 1, e, f)) +
            (checkRight(a, b, c, d, e + 1, f)) +
            (checkRight(a, b, c, d, e - 1, f)) +
            (checkRight(a, b, c, d, e, f - 1)) +
            (checkRight(a, b, c, d, e, f + 1));
    if (x >= 1)
      cout << "ALMOST";
    else
      cout << "NEITHER";
  }
}
