#include <bits/stdc++.h>
using namespace std;
complex<double> p, q, r, a, b, c;
double dot(complex<double> a, complex<double> b) { return real(conj(a) * b); }
double cro(complex<double> a, complex<double> b) { return imag(conj(a) * b); }
double right() {
  a = q - p, b = r - p, c = r - q;
  if (fabs(cro(a, b)) < 1e-9) return 0;
  return fabs(dot(a, b)) < 1e-9 || fabs(dot(b, c)) < 1e-9 ||
         fabs(dot(c, a)) < 1e-9;
}
int main() {
  double x, y, xx, yy, xxx, yyy;
  cin >> x >> y >> xx >> yy >> xxx >> yyy;
  p = complex<double>(x, y), q = complex<double>(xx, yy),
  r = complex<double>(xxx, yyy);
  if (right()) {
    cout << "RIGHT" << endl;
    return 0;
  }
  complex<double> d = complex<double>(1.0, 0.0);
  for (int i = 0; i < 4; i++) {
    p += d;
    if (right()) {
      cout << "ALMOST" << endl;
      return 0;
    }
    p -= d;
    d *= complex<double>(0.0, 1.0);
  }
  for (int i = 0; i < 4; i++) {
    q += d;
    if (right()) {
      cout << "ALMOST" << endl;
      return 0;
    }
    q -= d;
    d *= complex<double>(0.0, 1.0);
  }
  for (int i = 0; i < 4; i++) {
    r += d;
    if (right()) {
      cout << "ALMOST" << endl;
      return 0;
    }
    r -= d;
    d *= complex<double>(0.0, 1.0);
  }
  cout << "NEITHER" << endl;
}
