#include <bits/stdc++.h>
using namespace std;
bool right(int ds_ab, int ds_bc, int ds_ac) {
  if (ds_ab == (ds_ac + ds_bc)) {
    return true;
  }
  if (ds_bc == (ds_ac + ds_ab)) {
    return true;
  }
  if (ds_ac == (ds_ab + ds_bc)) {
    return true;
  }
  return false;
}
int main() {
  vector<pair<int, int> > coor;
  for (int i = 0; i < 3; i++) {
    int x, y;
    cin >> x >> y;
    coor.push_back(make_pair(x, y));
  }
  int ds_ab =
      (((coor[1].first - coor[0].first) * (coor[1].first - coor[0].first)) +
       (coor[1].second - coor[0].second) * (coor[1].second - coor[0].second));
  int ds_bc =
      (((coor[2].first - coor[1].first) * (coor[2].first - coor[1].first)) +
       (coor[2].second - coor[1].second) * (coor[2].second - coor[1].second));
  int ds_ac =
      (((coor[2].first - coor[0].first) * (coor[2].first - coor[0].first)) +
       (coor[2].second - coor[0].second) * (coor[2].second - coor[0].second));
  if (ds_ab <= 0 || ds_bc <= 0 || ds_ac <= 0) {
    cout << "NEITHER" << endl;
    return 0;
  }
  if (right(ds_ab, ds_bc, ds_ac)) {
    cout << "RIGHT" << endl;
    return 0;
  }
  for (int i = 0; i < 3; i++) {
    coor[i].first--;
    ds_ab =
        ((coor[1].first - coor[0].first) * (coor[1].first - coor[0].first) +
         (coor[1].second - coor[0].second) * (coor[1].second - coor[0].second));
    ds_bc =
        ((coor[2].first - coor[1].first) * (coor[2].first - coor[1].first) +
         (coor[2].second - coor[1].second) * (coor[2].second - coor[1].second));
    ds_ac =
        ((coor[2].first - coor[0].first) * (coor[2].first - coor[0].first) +
         (coor[2].second - coor[0].second) * (coor[2].second - coor[0].second));
    if (ds_ab <= 0 || ds_bc <= 0 || ds_ac <= 0) {
      coor[i].first++;
      continue;
    }
    if (right(ds_ab, ds_bc, ds_ac)) {
      cout << "ALMOST" << endl;
      return 0;
    }
    coor[i].first++;
  }
  for (int i = 0; i < 3; i++) {
    coor[i].first++;
    ds_ab =
        ((coor[1].first - coor[0].first) * (coor[1].first - coor[0].first) +
         (coor[1].second - coor[0].second) * (coor[1].second - coor[0].second));
    ds_bc =
        ((coor[2].first - coor[1].first) * (coor[2].first - coor[1].first) +
         (coor[2].second - coor[1].second) * (coor[2].second - coor[1].second));
    ds_ac =
        ((coor[2].first - coor[0].first) * (coor[2].first - coor[0].first) +
         (coor[2].second - coor[0].second) * (coor[2].second - coor[0].second));
    if (ds_ab <= 0 || ds_bc <= 0 || ds_ac <= 0) {
      coor[i].first--;
      continue;
    }
    if (right(ds_ab, ds_bc, ds_ac)) {
      cout << "ALMOST" << endl;
      return 0;
    }
    coor[i].first--;
  }
  for (int i = 0; i < 3; i++) {
    coor[i].second++;
    ds_ab =
        ((coor[1].first - coor[0].first) * (coor[1].first - coor[0].first) +
         (coor[1].second - coor[0].second) * (coor[1].second - coor[0].second));
    ds_bc =
        ((coor[2].first - coor[1].first) * (coor[2].first - coor[1].first) +
         (coor[2].second - coor[1].second) * (coor[2].second - coor[1].second));
    ds_ac =
        ((coor[2].first - coor[0].first) * (coor[2].first - coor[0].first) +
         (coor[2].second - coor[0].second) * (coor[2].second - coor[0].second));
    if (ds_ab <= 0 || ds_bc <= 0 || ds_ac <= 0) {
      coor[i].second--;
      continue;
    }
    if (right(ds_ab, ds_bc, ds_ac)) {
      cout << "ALMOST" << endl;
      return 0;
    }
    coor[i].second--;
  }
  for (int i = 0; i < 3; i++) {
    coor[i].second--;
    ds_ab =
        ((coor[1].first - coor[0].first) * (coor[1].first - coor[0].first) +
         (coor[1].second - coor[0].second) * (coor[1].second - coor[0].second));
    ds_bc =
        ((coor[2].first - coor[1].first) * (coor[2].first - coor[1].first) +
         (coor[2].second - coor[1].second) * (coor[2].second - coor[1].second));
    ds_ac =
        ((coor[2].first - coor[0].first) * (coor[2].first - coor[0].first) +
         (coor[2].second - coor[0].second) * (coor[2].second - coor[0].second));
    if (ds_ab <= 0 || ds_bc <= 0 || ds_ac <= 0) {
      coor[i].second++;
      continue;
    }
    if (right(ds_ab, ds_bc, ds_ac)) {
      cout << "ALMOST" << endl;
      return 0;
    }
    coor[i].second++;
  }
  cout << "NEITHER" << endl;
  return 0;
}
