#include <bits/stdc++.h>
using namespace std;
int dx[] = {-1, 0, 1, 0}, dy[] = {0, 1, 0, -1};
bool test(int x1, int y1, int x2, int y2, int x3, int y3) {
  int d1 = (x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1);
  int d2 = (x3 - x1) * (x3 - x1) + (y3 - y1) * (y3 - y1);
  int d3 = (x3 - x2) * (x3 - x2) + (y3 - y2) * (y3 - y2);
  if (!d1 || !d2 || !d3) return 0;
  if (d1 == d2 + d3 || d2 == d1 + d3 || d3 == d1 + d2) return 1;
  return 0;
}
int main() {
  int x1, y1, x2, y2, x3, y3;
  cin >> x1 >> y1 >> x2 >> y2 >> x3 >> y3;
  if (test(x1, y1, x2, y2, x3, y3)) {
    cout << "RIGHT";
    return 0;
  }
  bool almost = 0;
  for (int i = 0; i < 4; i++) {
    almost |= test(x1 + dx[i], y1 + dy[i], x2, y2, x3, y3);
    almost |= test(x1, y1, x2 + dx[i], y2 + dy[i], x3, y3);
    almost |= test(x1, y1, x2, y2, x3 + dx[i], y3 + dy[i]);
  }
  if (almost)
    cout << "ALMOST";
  else
    cout << "NEITHER";
}
