#include <bits/stdc++.h>
using namespace std;
int right_angled(int v[]) {
  int temp_c1, temp_c2, temp_h;
  int a = pow((v[0] - v[2]), 2) + pow((v[1] - v[3]), 2);
  int b = pow((v[0] - v[4]), 2) + pow((v[1] - v[5]), 2);
  int c = pow((v[4] - v[2]), 2) + pow((v[5] - v[3]), 2);
  if (a == 0 || b == 0 || c == 0) {
    return 0;
  }
  if (a >= b && a >= c) {
    temp_h = a;
    temp_c1 = b;
    temp_c2 = c;
  } else if (c >= a && c >= b) {
    temp_h = c;
    temp_c1 = a;
    temp_c2 = b;
  } else if (b >= a && b >= c) {
    temp_h = b;
    temp_c1 = a;
    temp_c2 = c;
  }
  if (temp_h == temp_c2 + temp_c1)
    return 1;
  else
    return 0;
}
int main() {
  int v[6], temp;
  for (int i = 0; i < 6; i++) {
    cin >> v[i];
  }
  if (right_angled(v)) {
    cout << "RIGHT" << endl;
    return 0;
  }
  for (int i = 0; i < 6; i++) {
    v[i]++;
    if (right_angled(v)) {
      cout << "ALMOST" << endl;
      break;
    }
    v[i] -= 2;
    if (right_angled(v)) {
      cout << "ALMOST" << endl;
      break;
    }
    v[i]++;
  }
  if (!right_angled(v)) {
    cout << "NEITHER" << endl;
  }
  return 0;
}
