#include <bits/stdc++.h>
const int mxn = 100000 + 10;
using namespace std;
int n;
int a[128];
int main() {
  cin >> n;
  for (int i = 0; i < n; i++) cin >> a[i];
  for (int i = 0; i < n; i++)
    for (int j = 0; j < n; j++)
      if (j != i)
        for (int k = 0; k < n; k++)
          if (k != j && j != i)
            if (a[i] == a[j] + a[k]) {
              printf("%d %d %d\n", i + 1, j + 1, k + 1);
              return 0;
            }
  puts("-1");
}
