#include <bits/stdc++.h>
using namespace std;
const int M = 101;
int inf = 1e9 + 1;
int n, arr[M];
int main() {
  ios::sync_with_stdio(0), cin.tie(NULL), cout.tie(NULL);
  cin >> n;
  for (int i = 0; i < n; i++) cin >> arr[i];
  for (int i = 0; i < n; i++)
    for (int j = 0; j < n; j++)
      for (int k = 0; k < n; k++)
        if (arr[i] == arr[j] + arr[k] && (i != j && i != k && k != j)) {
          cout << i + 1 << " " << j + 1 << " " << k + 1;
          return 0;
        }
  cout << "-1";
}
