#include <bits/stdc++.h>
using namespace std;
bool check(long double x1, long double y1, long double x2, long double y2,
           long double x3, long double y3) {
  long double d1 = (y2 - y1) * (y2 - y1) + (x2 - x1) * (x2 - x1);
  long double d2 = (y3 - y1) * (y3 - y1) + (x3 - x1) * (x3 - x1);
  long double d3 = (y3 - y2) * (y3 - y2) + (x3 - x2) * (x3 - x2);
  if ((d1 + d2 == d3 || d1 + d3 == d2 || d2 + d3 == d1) && (d1 > 0) &&
      (d2 > 0) && (d3 > 0)) {
    return true;
  }
  return false;
}
int main() {
  long double x1, y1, x2, y2, x3, y3;
  cin >> x1 >> y1 >> x2 >> y2 >> x3 >> y3;
  if (check(x1, y1, x2, y2, x3, y3)) {
    cout << "RIGHT" << endl;
    return 0;
  }
  long double dx[] = {-1, 0, 1, 0};
  long double dy[] = {0, -1, 0, 1};
  for (int j = 0; j < 4; j++) {
    long double x = dx[j] + x1;
    long double y = dy[j] + y1;
    if (check(x, y, x2, y2, x3, y3)) {
      cout << "ALMOST" << endl;
      return 0;
    }
  }
  for (int j = 0; j < 4; j++) {
    long double x = dx[j] + x2;
    long double y = dy[j] + y2;
    if (check(x1, y1, x, y, x3, y3)) {
      cout << "ALMOST" << endl;
      return 0;
    }
  }
  for (int j = 0; j < 4; j++) {
    long double x = dx[j] + x3;
    long double y = dy[j] + y3;
    if (check(x1, y1, x2, y2, x, y)) {
      cout << "ALMOST" << endl;
      return 0;
    }
  }
  cout << "NEITHER" << endl;
  return 0;
}
