#include <bits/stdc++.h>
using namespace std;
double square_edge_length(const pair<int, int>& x, const pair<int, int>& y) {
  double s1 = pow(x.first - y.first, 2);
  double s2 = pow(x.second - y.second, 2);
  return s1 + s2;
}
bool same_vertex(const pair<int, int>& v1, const pair<int, int>& v2) {
  if (v1.first == v2.first && v1.second == v2.second) return true;
  return false;
}
bool is_right(const vector<pair<int, int> >& triangle) {
  pair<int, int> v1 = triangle[0];
  pair<int, int> v2 = triangle[1];
  pair<int, int> v3 = triangle[2];
  vector<double> squared_sides;
  if (same_vertex(v1, v2)) return false;
  if (same_vertex(v1, v3)) return false;
  if (same_vertex(v2, v3)) return false;
  squared_sides.push_back(square_edge_length(v1, v2));
  squared_sides.push_back(square_edge_length(v1, v3));
  squared_sides.push_back(square_edge_length(v2, v3));
  sort(squared_sides.begin(), squared_sides.end());
  if (squared_sides[0] + squared_sides[1] == squared_sides[2]) return true;
  return false;
}
int main() {
  vector<pair<int, int> > triangle(3);
  int x, y;
  string result = " ";
  for (int i = 0; i < 3; ++i) {
    cin >> x;
    cin >> y;
    triangle[i].first = x;
    triangle[i].second = y;
  }
  if (is_right(triangle)) {
    result = "RIGHT";
  } else {
    triangle[0].first++;
    if (is_right(triangle)) result = "ALMOST";
    triangle[0].first--;
    triangle[0].first--;
    if (is_right(triangle)) result = "ALMOST";
    triangle[0].first++;
    triangle[0].second++;
    if (is_right(triangle)) result = "ALMOST";
    triangle[0].second--;
    triangle[0].second--;
    if (is_right(triangle)) result = "ALMOST";
    triangle[0].second++;
    triangle[1].first++;
    if (is_right(triangle)) result = "ALMOST";
    triangle[1].first--;
    triangle[1].first--;
    if (is_right(triangle)) result = "ALMOST";
    triangle[1].first++;
    triangle[1].second++;
    if (is_right(triangle)) result = "ALMOST";
    triangle[1].second--;
    triangle[1].second--;
    if (is_right(triangle)) result = "ALMOST";
    triangle[1].second++;
    triangle[2].first++;
    if (is_right(triangle)) result = "ALMOST";
    triangle[2].first--;
    triangle[2].first--;
    if (is_right(triangle)) result = "ALMOST";
    triangle[2].first++;
    triangle[2].second++;
    if (is_right(triangle)) result = "ALMOST";
    triangle[2].second--;
    triangle[2].second--;
    if (is_right(triangle)) result = "ALMOST";
    triangle[2].second++;
  }
  if (result == " ") {
    result = "NEITHER";
  }
  cout << result << '\n';
  return 0;
}
