#include <bits/stdc++.h>
using namespace std;
bool rightCheck(int x1, int y1, int x2, int y2, int x3, int y3) {
  int len12 = (x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2);
  int len23 = (x2 - x3) * (x2 - x3) + (y2 - y3) * (y2 - y3);
  int len31 = (x3 - x1) * (x3 - x1) + (y3 - y1) * (y3 - y1);
  if (len12 == 0 || len23 == 0 || len31 == 0) {
    return false;
  }
  int a, b, c;
  if (max(len12, max(len23, len31)) == len12) {
    a = len23;
    b = len31;
    c = len12;
  } else if (max(len12, max(len23, len31)) == len23) {
    a = len12;
    b = len31;
    c = len23;
  } else {
    a = len12;
    b = len23;
    c = len31;
  }
  if (a + b == c) {
    return true;
  } else {
    return false;
  }
}
int main() {
  int x1, y1, x2, y2, x3, y3;
  cin >> x1 >> y1 >> x2 >> y2 >> x3 >> y3;
  int offX[4] = {-1, 1, 0, 0};
  int offY[4] = {0, 0, -1, 1};
  if (rightCheck(x1, y1, x2, y2, x3, y3)) {
    cout << "RIGHT";
  } else {
    for (int i = 0; i < 4; ++i) {
      if (rightCheck(offX[i] + x1, offY[i] + y1, x2, y2, x3, y3)) {
        cout << "ALMOST";
        return 0;
      }
    }
    for (int i = 0; i < 4; ++i) {
      if (rightCheck(x1, y1, offX[i] + x2, offY[i] + y2, x3, y3)) {
        cout << "ALMOST";
        return 0;
      }
    }
    for (int i = 0; i < 4; ++i) {
      if (rightCheck(x1, y1, x2, y2, offX[i] + x3, offY[i] + y3)) {
        cout << "ALMOST";
        return 0;
      }
    }
    cout << "NEITHER";
    return 0;
  }
}
