#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long int n;
  cin >> n;
  long long int a[n + 1];
  for (long long int i = 1; i <= n; i++) {
    cin >> a[i];
  }
  long long int f = 0;
  for (long long int i = 1; i <= n; i++) {
    for (long long int j = 1; j <= n; j++) {
      if (j != i) {
        for (long long int k = 1; k <= n; k++) {
          if (k != j) {
            if (a[i] == a[j] + a[k]) {
              f = 1;
              cout << i << " " << j << " " << k << endl;
              break;
            }
          }
        }
        if (f) {
          break;
        }
      }
    }
    if (f) {
      break;
    }
  }
  if (f == 0) {
    cout << -1;
  }
  return 0;
}
