#include <bits/stdc++.h>
using namespace std;
int diff[4][2] = {{1, 0}, {-1, 0}, {0, 1}, {0, -1}};
int dist2(pair<int, int> a, pair<int, int> b) {
  return (pow(a.first - b.first, 2) + pow(a.second - b.second, 2));
}
bool is_right(pair<int, int> a, pair<int, int> b, pair<int, int> c) {
  int ab = dist2(a, b), bc = dist2(b, c), ca = dist2(c, a);
  return ((ab == bc + ca) || (bc == ca + ab) || (ca == ab + bc)) &&
         ((ab * bc * ca));
}
int main() {
  pair<int, int> p[3];
  cin >> p[0].first >> p[0].second >> p[1].first >> p[1].second >> p[2].first >>
      p[2].second;
  if (is_right(p[0], p[1], p[2])) {
    cout << "RIGHT" << endl;
    return 0;
  }
  for (int i = 0; i < 3; i++)
    for (int j = 0; j < 4; j++)
      if (is_right(
              pair<int, int>(p[i].first + diff[j][0], p[i].second + diff[j][1]),
              p[(i + 1) % 3], p[(i + 2) % 3])) {
        cout << "ALMOST" << endl;
        return 0;
      }
  cout << "NEITHER" << endl;
}
