#include <bits/stdc++.h>
using namespace std;
const int MAX = 1e6 + 10;
const int OO = 0x3f3f3f3f;
const double EPS = 1e-9;
bool is(complex<long long> a, complex<long long> b, complex<long long> c) {
  if (a == b or a == c or b == c) return false;
  vector<int> arr;
  arr.push_back((a.real() - b.real()) * (a.real() - b.real()) +
                (a.imag() - b.imag()) * (a.imag() - b.imag()));
  arr.push_back((a.real() - c.real()) * (a.real() - c.real()) +
                (a.imag() - c.imag()) * (a.imag() - c.imag()));
  arr.push_back((c.real() - b.real()) * (c.real() - b.real()) +
                (c.imag() - b.imag()) * (c.imag() - b.imag()));
  sort(arr.begin(), arr.end());
  return arr[2] == arr[1] + arr[0];
}
int dx[] = {1, 0, -1, 0};
int dy[] = {0, 1, 0, -1};
int main() {
  long long x, y;
  cin >> x >> y;
  complex<long long> p1(x, y);
  cin >> x >> y;
  complex<long long> p2(x, y);
  cin >> x >> y;
  complex<long long> p3(x, y);
  bool fl = is(p1, p2, p3);
  if (fl)
    cout << "RIGHT\n";
  else {
    for (int i = 0; i < 4; i++) {
      complex<long long> a(p1.real() + dx[i], p1.imag() + dy[i]);
      fl = is(a, p2, p3) or fl;
    }
    for (int i = 0; i < 4; i++) {
      complex<long long> a(p2.real() + dx[i], p2.imag() + dy[i]);
      fl = is(a, p1, p3) or fl;
    }
    for (int i = 0; i < 4; i++) {
      complex<long long> a(p3.real() + dx[i], p3.imag() + dy[i]);
      fl = is(a, p2, p1) or fl;
    }
    if (fl)
      cout << "ALMOST\n";
    else
      cout << "NEITHER\n";
  }
  return 0;
}
