#include <bits/stdc++.h>
using namespace std;
int cnt;
vector<int> nums;
int n, m;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr);
  cin >> cnt;
  m = -1;
  for (int i = 0; i < cnt; ++i) {
    int temp;
    cin >> temp;
    nums.push_back(temp);
  }
  if (nums.size() == 1) {
    cout << "YES" << endl;
    cout << 1000000000 << " " << 1000000000 << endl;
    return 0;
  }
  auto lit = nums.begin();
  auto rit = nums.begin();
  ++rit;
  while (rit != nums.end()) {
    int l = *lit;
    int r = *rit;
    if (l == r) {
      cout << "NO" << endl;
      return 0;
    }
    if (abs(l - r) != 1) {
      if (m == -1)
        m = abs(l - r);
      else {
        if (m != abs(l - r)) {
          cout << "NO" << endl;
          return 0;
        }
      }
    }
    ++lit;
    ++rit;
  }
  if (m == -1) {
    cout << "YES" << endl;
    cout << 1000000000 << " " << 1 << endl;
    return 0;
  }
  lit = nums.begin();
  rit = nums.begin();
  ++rit;
  while (rit != nums.end()) {
    int l = *lit;
    int r = *rit;
    vector<int> possibleMoves;
    if (l + m > 0) possibleMoves.push_back(l + m);
    if (l - m > 0) possibleMoves.push_back(l - m);
    if (l % m != 1) possibleMoves.push_back(l - 1);
    if (l % m != 0) possibleMoves.push_back(l + 1);
    if (find(possibleMoves.begin(), possibleMoves.end(), r) ==
        possibleMoves.end()) {
      cout << "NO" << endl;
      return 0;
    }
    ++lit;
    ++rit;
  }
  cout << "YES" << endl;
  cout << 1000000000 << " " << m << endl;
  return 0;
}
