#include<bits/stdc++.h>
using namespace std;

#define INF (1 << 29)

int main(){
  int n;
  vector<int> a;
  int temp;
  scanf("%d",&n);
  for(int i = 0;i < n;++i){
    scanf("%d",&temp);
    a.push_back(temp);
  }
  sort(a.begin(), a.end());
  double ans = 0;
  for(int i = 0;i <= n - 4;++i){
    ans = max(ans, (double)((double)(a[n - 1] + a[n - 2]) / (double)(a[i + 1] - a[i])));
  }
  ans = max(ans, (double)((double)(a[n - 3] + a[n - 4]) / (double)(a[n - 1] - a[n - 2])));
  ans = max(ans, (double)((double)(a[n - 1] + a[n - 4]) / (double)(a[n - 2] - a[n - 3])));
  printf("%.6lf\n",ans);
  return 0;
}
