#include <bits/stdc++.h>
using namespace std;
void solve() {
  int n;
  cin >> n;
  vector<int> a(n);
  for (int i = 0; i < n; ++i) {
    cin >> a[i];
  }
  sort(a.begin(), a.end());
  if (n == 1) {
    cout << "-1\n";
    return;
  }
  if (n == 2 and a[0] != a[1]) {
    set<int> ans;
    int d = a[1] - a[0];
    ans.insert(a[0] - d);
    ans.insert(a[1] + d);
    if (d % 2 == 0) {
      ans.insert((a[0] + a[1]) / 2);
    }
    cout << ((int)ans.size()) << '\n';
    for (int i : ans) cout << i << " ";
    return;
  }
  set<int> diff;
  for (int i = 0; i < n - 1; ++i) {
    diff.insert(a[i + 1] - a[i]);
  }
  if (((int)diff.size()) == 1) {
    set<int> ans;
    int d = *diff.begin();
    ans.insert(a[0] - d);
    ans.insert(a.back() + d);
    cout << ((int)ans.size()) << '\n';
    for (int i : ans) cout << i << " ";
    return;
  } else if (((int)diff.size()) > 2 ||
             (((int)diff.size()) > 1 and *diff.begin() * 2 != *diff.rbegin())) {
    cout << "0\n";
  } else {
    vector<int> ans;
    for (int i = 0; i < n - 1; ++i) {
      if (a[i + 1] - a[i] == *diff.rbegin()) {
        ans.push_back(a[i] + *diff.begin());
      }
    }
    if (((int)ans.size()) > 1) {
      cout << 0 << '\n';
    } else {
      sort(ans.begin(), ans.end());
      cout << 1 << '\n';
      cout << ans[0] << '\n';
    }
  }
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int t = 1;
  while (t--) {
    solve();
  }
}
