# include<bits/stdc++.h>

#define all(x) begin(x), end(x)
#define rall(x) (x).rbegin(), (x).rend()
#define sz(x) ((int)(x).size())
#define pb push_back
#define eb emplace_back
#define fi first
#define se second
#define mp make_pair
#define input freopen("input.txt","r",stdin);
#define output freopen("output.txt","w",stdout);
#define fast_io ios::sync_with_stdio(NULL), cin.tie(NULL), cout.tie(NULL);
#define fix cout << fixed << setprecision(15);
//#define left left228
//#define right right228
//#define next next228
#define rank rank228
//#define prev prev228
#define y1 y1228
#define dout if(debug) cout
using namespace std;
using ll = long long;
using ull = unsigned long long;
using ld = long double;
using pii = pair<int, int> ;
using pll = pair<ll, ll>;
using pci = pair<char, int>;
using vi = vector<int> ;
using vll = vector<ll> ;
using vpii = vector<pii> ;
const ll infll = 1e18 + 3;
const int maxn = 1e6 + 77;
const int nmax = 1e6 + 577;
const ll basell = 1e18 + 3;
const int mod = 1e9 + 7;
const ld eps = 1e-7;
const int inf = 1009000999;
const int nv = 100505;
const int baseint = 1000200013;
const ld PI = acos(-1.0);
inline bool EQ(ld a, ld b) { return fabs(a-b) < 1e-9; }
inline bool IF(int a, int b, int c) { return (a >= b && a <= c); }
inline bool IFS(int a, int b, int c) { return (a > b && a < c); }
template<typename T> inline istream &operator>> (istream &_in, vector<T> &_v) { for (auto &_i : _v) { _in >> _i; } return _in; }
mt19937 rnd(chrono::high_resolution_clock::now().time_since_epoch().count());
//typedef pair<int, int> pt;
//#define x first
//#define y second
//ifstream cin("input.txt");
//ofstream cout("output.txt");
/*
sort(a, a + n, [&](pair<pt, int> a, pair<pt, int> b){if (a.x.x != b.x.x)
        return a.x.x < b.x.x; return a.x.y > b.x.y;});
for(int c : s)
for(int &i : a) cin >> i;
for(int c = 'a'; c <= 'z'; ++c)
vector<vector<ll>> dp(n, vector<ll>(n+2));
__int128;
char 0 = int 48;
char c = cin;
int h = (int)c - 48;
*/

/*char memory[(int)1e8];

char memorypos;

inline void * operator new(size_t n){
    char * ret = memory + memorypos;
    memorypos += n;
    return (void *)ret;
}

inline void operator delete(void *){}
*/

int x[nv], v[nv];

int inline solve() {
    //input;//,output;
    fix;
    fast_io;
    int n;
    cin >> n;
    for (int i = 0; i < n; ++i) {
        cin >> x[i];
    }
    for (int i = 0; i < n; ++i) {
        cin >> v[i];
    }
    ld l = 0, r = inf;
    ld t = inf;
    while(l < r){
        ld m = (r + l)/2;
        ld L = 0, R = inf;
        for (int i = 0; i < n; ++i) {
            L = max(L, (ld)(x[i]) - v[i] * m);
            R = min(R, (ld)(x[i]) + v[i] * m);
        }
        if(L <= R){
            r = m;
            t = min(t, m);
        } else {
            l = m + eps * 100;
        }
    }
    cout << l;
    return 0;
}

int32_t main() {
    //freopen("input.txt", "r", stdin);
    //freopen("output.txt", "w", stdout);
    solve();
    return 0;
}
/*
 * */


# include<bits/stdc++.h>

#define all(x) begin(x), end(x)
#define rall(x) (x).rbegin(), (x).rend()
#define sz(x) ((int)(x).size())
#define pb push_back
#define eb emplace_back
#define fi first
#define se second
#define mp make_pair
#define input freopen("input.txt","r",stdin);
#define output freopen("output.txt","w",stdout);
#define fast_io ios::sync_with_stdio(NULL), cin.tie(NULL), cout.tie(NULL);
#define fix cout << fixed << setprecision(15);
//#define left left228
//#define right right228
//#define next next228
#define rank rank228
//#define prev prev228
#define y1 y1228
#define dout if(debug) cout
using namespace std;
using ll = long long;
using ull = unsigned long long;
using ld = long double;
using pii = pair<int, int> ;
using pll = pair<ll, ll>;
using pci = pair<char, int>;
using vi = vector<int> ;
using vll = vector<ll> ;
using vpii = vector<pii> ;
const ll infll = 1e18 + 3;
const int maxn = 1e6 + 77;
const int nmax = 1e6 + 577;
const ll basell = 1e18 + 3;
const int mod = 1e9 + 7;
const ld eps = 1e-7;
const int inf = 1009000999;
const int nv = 100505;
const int baseint = 1000200013;
const ld PI = acos(-1.0);
inline bool EQ(ld a, ld b) { return fabs(a-b) < 1e-9; }
inline bool IF(int a, int b, int c) { return (a >= b && a <= c); }
inline bool IFS(int a, int b, int c) { return (a > b && a < c); }
template<typename T> inline istream &operator>> (istream &_in, vector<T> &_v) { for (auto &_i : _v) { _in >> _i; } return _in; }
mt19937 rnd(chrono::high_resolution_clock::now().time_since_epoch().count());
//typedef pair<int, int> pt;
//#define x first
//#define y second
//ifstream cin("input.txt");
//ofstream cout("output.txt");
/*
sort(a, a + n, [&](pair<pt, int> a, pair<pt, int> b){if (a.x.x != b.x.x)
        return a.x.x < b.x.x; return a.x.y > b.x.y;});
for(int c : s)
for(int &i : a) cin >> i;
for(int c = 'a'; c <= 'z'; ++c)
vector<vector<ll>> dp(n, vector<ll>(n+2));
__int128;
char 0 = int 48;
char c = cin;
int h = (int)c - 48;
*/

/*char memory[(int)1e8];

char memorypos;

inline void * operator new(size_t n){
    char * ret = memory + memorypos;
    memorypos += n;
    return (void *)ret;
}

inline void operator delete(void *){}
*/

int x[nv], v[nv];

int inline solve() {
    //input;//,output;
    fix;
    fast_io;
    int n;
    cin >> n;
    for (int i = 0; i < n; ++i) {
        cin >> x[i];
    }
    for (int i = 0; i < n; ++i) {
        cin >> v[i];
    }
    ld l = 0, r = 2 * n;
    ld t = inf;
    while(l < r){
        ld m = (r + l)/2;
        ld L = 0, R = inf;
        for (int i = 0; i < n; ++i) {
            L = max(L, (ld)(x[i]) - v[i] * m);
            R = min(R, (ld)(x[i]) + v[i] * m);
        }
        if(L <= R){
            r = m;
            t = min(t, m);
        } else {
            l = m + eps;
        }
        if(EQ(l, r)) break;
    }
    cout << l;
    return 0;
}

int32_t main() {
    //freopen("input.txt", "r", stdin);
    //freopen("output.txt", "w", stdout);
    solve();
    return 0;
}
/*
 * */


#include<bits/stdc++.h>

using namespace std;

typedef long long ll;
typedef long double ld;
typedef unsigned long long ull;
typedef pair<int,int> pii;
typedef pair<ll,ll> pll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<char> vc;
typedef vector<bool> vb;

const int MAXN = 60005;
const int INF = 1e9;
const ld dif = 1e-6;

ld x[MAXN], v[MAXN];

int n;

bool check(ld m){
    ld l = x[0]-v[0]*m, r = x[0]+v[0]*m;
    for(int i=1; i<n; i++){
        if((x[i]-v[i]*m) > r || (x[i]+v[i]*m) < l)
            return false;
        if((x[i]-v[i]*m) > l)
            l = x[i]-v[i]*m;
        if((x[i]+v[i]*m) < r)
            r = x[i]+v[i]*m;
    }
    return true;
}

int main(){
    ios::sync_with_stdio(false); cin.tie(0);

    cin >> n;

    for(int i=0; i<n; i++)
        cin >> x[i];

    for(int i=0; i<n; i++)
        cin >> v[i];

    ld l=0, r=INF, m;
    while((l+dif) < r){
        m = (l+r)/2;
        if(check(m))
            r = m;
        else
            l = m;
    }

    cout << fixed << setprecision(12) << l << '\n';

    return 0;
}


#include<bits/stdc++.h>

using namespace std;

typedef long long ll;
typedef long double ld;
typedef unsigned long long ull;
typedef pair<int,int> pii;
typedef pair<ll,ll> pll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<char> vc;
typedef vector<bool> vb;

const int MAXN = 60005;
const int INF = 1e9;
const ld dif = 1e-12;

ld x[MAXN], v[MAXN];

int n;

bool check(ld m){
    ld l = x[0]-v[0]*m, r = x[0]+v[0]*m;
    for(int i=1; i<n; i++){
        if((x[i]-v[i]*m) > r || (x[i]+v[i]*m) < l)
            return false;
        if((x[i]-v[i]*m) > l)
            l = x[i]-v[i]*m;
        if((x[i]+v[i]*m) < r)
            r = x[i]+v[i]*m;
    }
    return true;
}

int main(){
    ios::sync_with_stdio(false); cin.tie(0);

    cin >> n;

    for(int i=0; i<n; i++)
        cin >> x[i];

    for(int i=0; i<n; i++)
        cin >> v[i];

    ld l=0, r=INF, m;
    while((l+dif) < r){
        m = (l+r)/2;
        if(check(m))
            r = m;
        else
            l = m;
    }

    cout << fixed << setprecision(12) << l << '\n';

    return 0;
}


#include <iostream>
#include <vector>
#include <algorithm>
#include <iomanip>
#define pt pair<double,double>
using namespace std;
vector<int> pos, vel;
int n;
const double eps = 1e-18;
vector<pt> intervals;
bool valid(double time)
{
	vector<pair<double, int> > events;
	for(int i=0; i<n; i++){
		events.emplace_back(pos[i] - vel[i] * time, -1);
		events.emplace_back(pos[i] + vel[i] * time, 1);
	}
	sort(events.begin(), events.end());
	int cnt = 0;
	for(auto &e:events){
		cnt -= e.second;
		if(cnt == n){
			return true;
		}
	}
	return false;
}
int main()
{
	cin >> n;
	pos.resize(n); vel.resize(n); intervals.resize(n);
	for (size_t i = 0; i < n; i++) cin >> pos[i];
	for (size_t i = 0; i < n; i++) cin >> vel[i];
	double st = 0, sz = 1e9;
	for (sz /= 2; sz > eps; sz /= 2)
	{
		double mid = st + sz;
		if (!valid(mid))
			st = mid;
	}
	cout << setprecision(10) << fixed << st+sz << endl;
	return 0;
}


#include <bits/stdc++.h>

using namespace std;
const int OO = 2e9;
const int N = 60005;
int n;
int pos[N], v[N];

pair<double , double > valid(double tm) {

    pair<double, double> intersect = {-OO, OO};
    for (int i = 0; i < n; i++) {
        intersect.first = max(intersect.first, pos[i] - v[i] * tm);
        intersect.second = min(intersect.second, pos[i] + v[i] * tm);
    }
    return intersect.first <= intersect.second;
}

int main() {

    scanf("%d", &n);
    for (int i = 0; i < n; i++)
        scanf("%d", pos + i);
    for (int i = 0; i < n; i++)
        scanf("%d", v + i);

    double st = 0, sz = OO;
    for (sz /= 2; sz > 1e-9; sz /= 2) {
        double  md = st + sz;
        auto p = valid(md);
        if (valid(md)) {
            st = md;
        }
    }
    printf("%.6lf", st + sz / 2);
}


#include <bits/stdc++.h>

using namespace std;
const int OO = 2e9;
const int N = 60005;
int n;
int pos[N], v[N];

bool valid(double tm) {

    pair<double, double> intersect = {-OO, OO};
    for (int i = 0; i < n; i++) {
        intersect.first = max(intersect.first, pos[i] - v[i] * tm);
        intersect.second = min(intersect.second, pos[i] + v[i] * tm);
    }
    return intersect.first <= intersect.second;
}

int main() {

    scanf("%d", &n);
    for (int i = 0; i < n; i++)
        scanf("%d", pos + i);
    for (int i = 0; i < n; i++)
        scanf("%d", v + i);

    double st = 0, sz = OO;
    for (sz /= 2; sz > 1e-9; sz /= 2) {
        double  md = st + sz;
        auto p = valid(md);
        if (valid(md)) {
            st = md;
        }
    }
    printf("%.6lf", st + sz / 2);
}


#include <bits/stdc++.h>

using namespace std;
const int OO = 2e9;
const int N = 60005;
int n;
int pos[N], v[N];

bool valid(double tm) {

    pair<double, double> intersect = {-OO, OO};
    for (int i = 0; i < n; i++) {
        intersect.first = max(intersect.first, pos[i] - v[i] * tm);
        intersect.second = min(intersect.second, pos[i] + v[i] * tm);
    }
    return intersect.first <= intersect.second;
}

int main() {

    scanf("%d", &n);
    for (int i = 0; i < n; i++)
        scanf("%d", pos + i);
    for (int i = 0; i < n; i++)
        scanf("%d", v + i);

    double st = 0, sz = OO;
    for (sz /= 2; sz > 1e-9; sz /= 2) {
        double  md = st + sz;
        auto p = valid(md);
        if (!valid(md)) {
            st = md;
        }
    }
    printf("%.6lf", st + sz / 2);
}


#include <bits/stdc++.h>

using namespace std;
const int OO = 2e9;
const int N = 60005;
int n;
int pos[N], v[N];

pair<double , double > valid(double tm) {

    pair<double, double> intersect = {-OO, OO};
    for (int i = 0; i < n; i++) {
        intersect.first = max(intersect.first, pos[i] - v[i] * tm);
        intersect.second = min(intersect.second, pos[i] + v[i] * tm);
    }
    return intersect;
}

int main() {

    scanf("%d", &n);
    for (int i = 0; i < n; i++)
        scanf("%d", pos + i);
    for (int i = 0; i < n; i++)
        scanf("%d", v + i);

    double st = 0, sz;
    for (sz = OO / 2; sz > 1e-9; sz /= 2) {
        double  md = st + sz/2;
        auto p = valid(md);
        if (p.second <= p.first) {
            st += sz/2;
        }
    }
    printf("%.6lf", st + sz / 2);
}


// https://cp-algorithms.com/num_methods/ternary_search.html
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;

int main() {
    ll n;
    ll x;
    cin >> n;
    cout << fixed << setprecision(7);
    vector<ll> crd, spd;
    for (ll i=0; i<n; i++) {
        cin >> x;
        crd.push_back(x);
    }
    for (ll i=0; i<n; i++) {
        cin >> x;
        spd.push_back(x);
    }
    double l = 1, r = 1000000000, fa, fb;
    double lim = 1e-7;
    while (r-l>lim) {
        fa = 0;
        fb = 0;
        double a = l+(r-l)/3;
        double b = r-(r-l)/3;
        for (ll i=0; i<n; i++) {
            fa = max(fa,abs(crd[i]-a)/spd[i]);
            fb = max(fb,abs(crd[i]-b)/spd[i]);
        }
        if (fa<fb) r = b;
        else l = a;
    }
    cout << fa;
    return 0;
}


// https://cp-algorithms.com/num_methods/ternary_search.html
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;

int main() {
    ll n;
    ll x;
    cin >> n;
    cout << fixed << setprecision(8);
    vector<ll> crd, spd;
    for (ll i=0; i<n; i++) {
        cin >> x;
        crd.push_back(x);
    }
    for (ll i=0; i<n; i++) {
        cin >> x;
        spd.push_back(x);
    }
    double l = 1, r = 1000000000, fa, fb;
    double lim = 1e-8;
    while (r-l>lim) {
        fa = 0;
        fb = 0;
        double a = l+(r-l)/3;
        double b = r-(r-l)/3;
        for (ll i=0; i<n; i++) {
            fa = max(fa,abs(crd[i]-a)/spd[i]);
            fb = max(fb,abs(crd[i]-b)/spd[i]);
        }
        if (fa<fb) r = b;
        else l = a;
    }
    cout << fa;
    return 0;
}


// https://cp-algorithms.com/num_methods/ternary_search.html
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;

int main() {
    ll n;
    double x;
    cin >> n;
    cout << fixed << setprecision(8);
    vector<double> crd, spd;
    for (ll i=0; i<n; i++) {
        cin >> x;
        crd.push_back(x);
    }
    for (ll i=0; i<n; i++) {
        cin >> x;
        spd.push_back(x);
    }
    double l = 1, r = 1000000000, fa, fb;
    double lim = 1e-8;
    while (r-l>lim) {
        fa = 0;
        fb = 0;
        double a = l+(r-l)/3;
        double b = r-(r-l)/3;
        for (ll i=0; i<n; i++) {
            fa = max(fa,abs(crd[i]-a)/spd[i]);
            fb = max(fb,abs(crd[i]-b)/spd[i]);
        }
        if (fa<fb) r = b;
        else l = a;
    }
    cout << fa;
    return 0;
}


#include <bits/stdc++.h>

#define int long long
#define double long double
#define pb push_back
#define endl '\n'
#define ff first
#define ss second
#define watch(x) cerr<<#x<<" is "<<x<<endl;

const int MAX = 60020;

using namespace std;

int n;
double x[MAX], v[MAX];

int32_t main ()
{
	ios_base::sync_with_stdio(0);
	cin.tie(0); cout.tie(0);
	cout.setf(ios::fixed);
	cout.precision(10);

    cin >> n;

    for (int i = 0; i < n; ++ i) cin >> x[i];
    for (int i = 0; i < n; ++ i) cin >> v[i];

    double l = 0, r = 1e9, m;
    while (r - l >= 1e-7)
    {
        m = (l + r) / 2;

        double maxL = 0, minR = 1e9;
        for (int i = 0; i < n; ++ i)
            maxL = max(maxL, x[i]-v[i]*m),
            minR = min(minR, x[i]+v[i]*m);

        if (minR - maxL >= 1e-7) r = m;
        else l = m;
    }

    cout << r << endl;

    return 0;
}


#include <bits/stdc++.h>

#define int long long
#define double long double
#define pb push_back
#define endl '\n'
#define ff first
#define ss second
#define watch(x) cerr<<#x<<" is "<<x<<endl;

const int MAX = 60020;

using namespace std;

int n;
double x[MAX], v[MAX];

int32_t main ()
{
	ios_base::sync_with_stdio(0);
	cin.tie(0); cout.tie(0);
	cout.setf(ios::fixed);
	cout.precision(10);

    cin >> n;

    for (int i = 0; i < n; ++ i) cin >> x[i];
    for (int i = 0; i < n; ++ i) cin >> v[i];

    double l = 0, r = 1e9, m;
    while (r - l >= 1e-6)
    {
        m = (l + r) / 2;

        double maxL = 0, minR = 1e9;
        for (int i = 0; i < n; ++ i)
            maxL = max(maxL, x[i]-v[i]*m),
            minR = min(minR, x[i]+v[i]*m);

        if (minR - maxL >= 1e-6) r = m;
        else l = m;
    }

    cout << r << endl;

    return 0;
}


#pragma GCC optimize ("O3")
#include<bits/stdc++.h>
#define ll long long
#define ld long double
#define OO 4e18
#define oo 1e9
#define yalla ios::sync_with_stdio(0),cin.tie(0),cout.tie(0);
#define FILES freopen("input.txt", "r", stdin); freopen("output.txt", "w", stdout);
#define sz  100005
#define re return
#define F first
#define S second
#define pll pair<ll,ll>
#define mod  1000000007
#define pi acos(-1)
using namespace std;
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
#define ordered_set tree<int,null_type,less<int>, rb_tree_tag,tree_order_statistics_node_update>
ll n;
ld v[sz],x[sz],ans=OO;
const ld eps=1e-9;
///
ld check(ld mid)
{ld tim=0;
 for(int i=0;i<n;i++)
  tim=max(tim,abs(x[i]-mid)/v[i]);
 re tim;
}
int main()
{
   yalla;
   cin>>n;
   for(int i=0;i<n;i++)cin>>x[i];
   for(int i=0;i<n;i++)cin>>v[i];
   ///
   ld lo=1,hi=1e9,mid;
   for(int y=0;y<200;y++)
   {mid=(lo+hi)/2.0;
    ld half=check(mid);
    ld ri=check(mid+eps);
    ld lf=check(mid-eps);
    ans=min(ans,half);
    ///
    if(lf<=ri)
      ans=min(ans,lf),hi=mid-eps;
    else
      lo=mid+eps;
   }
   cout<<fixed<<setprecision(12)<<ans<<endl;
  re 0;
}


#pragma GCC optimize ("O3")
#include<bits/stdc++.h>
#define ll long long
#define ld long double
#define OO 4e18
#define oo 1e9
#define yalla ios::sync_with_stdio(0),cin.tie(0),cout.tie(0);
#define FILES freopen("input.txt", "r", stdin); freopen("output.txt", "w", stdout);
#define sz  100005
#define re return
#define F first
#define S second
#define pll pair<ll,ll>
#define mod  1000000007
#define pi acos(-1)
using namespace std;
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
#define ordered_set tree<int,null_type,less<int>, rb_tree_tag,tree_order_statistics_node_update>
ll n;
ld v[sz],x[sz],ans=OO;
const ld eps=1e-9;
///
ld check(ld mid)
{ld tim=0;
 for(int i=0;i<n;i++)
  tim=max(tim,abs(x[i]-mid)/v[i]);
 re tim;
}
int main()
{
   yalla;
   cin>>n;
   for(int i=0;i<n;i++)cin>>x[i];
   for(int i=0;i<n;i++)cin>>v[i];
   ///
   ld lo=1,hi=1e9,mid;
   while(hi-lo>=eps)
   {mid=(lo+hi)/2.0;
    ld half=check(mid);
    ld ri=check(mid+eps);
    ld lf=check(mid-eps);
    ans=min(ans,half);
    ///
    if(lf<=ri)
      ans=min(ans,lf),hi=mid-eps;
    else
      lo=mid+eps;
   }
   cout<<fixed<<setprecision(12)<<ans<<endl;
  re 0;
}


#include <iostream>
#include <bits/stdc++.h>
#define ll  long long int
#define ld long double
using namespace std;
ll mod = 1000000007;
int n;
bool canReach(double time, vector<int> x, vector<int> v){
     double maxLeft = 0.0, minRight = (double)INT_MAX;
     for (int i = 0; i < n; ++i){
          double left = (double)x[i]-(time*v[i]);
          double right = (double)x[i]+(time*v[i]);
          maxLeft = max(left, maxLeft);
          minRight = min(right, minRight);
          if (maxLeft > minRight){
              return false;
          }
     }
     return true;
}
void solve(){
    cin >> n;
    vector<int> coordinate(n), velocity(n);
    for (int i = 0; i < n; ++i){
        cin >> coordinate[i];
    }
    for (int i = 0; i < n; ++i){
        cin >> velocity[i];
    }
    double left = 0.0, right = (double)1e9;
    while (right-left >= 1e-7){
        double time = 1.0*(left+right)/2;
        if (canReach(time, coordinate, velocity)){
            right = time;
        }else{
            left = time;
        }
    }
    cout << setprecision(20) << left << '\n';
}
int main()
{
    std::ios_base::sync_with_stdio(false);
    cin.tie(nullptr);
    int tests;
    solve();
    return 0;
}


#include <iostream>
#include <bits/stdc++.h>
#define ll  long long int
#define ld long double
using namespace std;
ll mod = 1000000007;
int n;
bool canReach(double time, vector<int> x, vector<int> v){
     double maxLeft = 0.0, minRight = (double)INT_MAX;
     for (int i = 0; i < n; ++i){
          double left = (double)x[i]-(time*v[i]);
          double right = (double)x[i]+(time*v[i]);
          maxLeft = max(left, maxLeft);
          minRight = min(right, minRight);
          if (maxLeft > minRight){
              return false;
          }
     }
     return true;
}
void solve(){
    cin >> n;
    vector<int> coordinate(n), velocity(n);
    for (int i = 0; i < n; ++i){
        cin >> coordinate[i];
    }
    for (int i = 0; i < n; ++i){
        cin >> velocity[i];
    }
    double left = 1, right = 1e9;
    while (right-left > 1e-7){
        double time = 1.0*(left+right)/2;
        if (canReach(time, coordinate, velocity)){
            right = time;
        }else{
            left = time;
        }
    }
    cout << setprecision(15) << left << '\n';
}
int main()
{
    std::ios_base::sync_with_stdio(false);
    cin.tie(nullptr);
    int tests;
    solve();
    return 0;
}


#define ll long long

#include <iostream>
#include <stdlib.h>
#include <string>
#include <algorithm>
#include <math.h>
#include <cstring>
#include <sstream>
#include <vector>
#include <map>
#include <set>
#include <queue>
#include <time.h>
#include <stack>

using namespace std;

const double DELTA=1e-7;

int n;
double x[1000000];
double v[1000000];

double time(double pos) {

	double ans=0;

	for (int i=1;i<=n;i++) ans=max(ans,max(pos-x[i],x[i]-pos)/v[i]);

	return ans;

}

double bsearch(double s, double e) {

	if (e-s<1e-3) {
		for (double x=s;x<=e;x+=DELTA) {
			if (time(x)<time(x+DELTA)) return x;
		}
		return e+DELTA;
	}

	double mid=(s+e)/2;
//	cout<<mid<<endl;

	if (time(mid)<time(mid+DELTA)) return bsearch(s,mid);
	else return bsearch(mid,e);

}

int main() {

	ios_base::sync_with_stdio(false);

	cin>>n;
	for (int i=1;i<=n;i++) cin>>x[i];
	for (int i=1;i<=n;i++) cin>>v[i];

	double ans=bsearch((double)1,(double)1e9);

	double myans=1e9;

	for (int i=1;i<=n;i++) {
		myans=min(myans,time(ans));
	}

	printf("%.9f",myans);

	return 0;

}


#define ll long long

#include <iostream>
#include <stdlib.h>
#include <string>
#include <algorithm>
#include <math.h>
#include <cstring>
#include <sstream>
#include <vector>
#include <map>
#include <set>
#include <queue>
#include <time.h>
#include <stack>

using namespace std;

const double DELTA=1e-7;

int n;
double x[1000000];
double v[1000000];

double time(double pos) {

	double ans=0;

	for (int i=1;i<=n;i++) ans=max(ans,max(pos-x[i],x[i]-pos)/v[i]);

	return ans;

}

double bsearch(double s, double e) {

	if (e-s<1e-6) {
		for (double x=s;x<=e;x+=DELTA) {
			if (time(x)<time(x+DELTA)) return x;
		}
		return e+DELTA;
	}

	double mid=(s+e)/2;
//	cout<<mid<<endl;

	if (time(mid)<time(mid+DELTA)) return bsearch(s,mid);
	else return bsearch(mid,e);

}

int main() {

	ios_base::sync_with_stdio(false);

	cin>>n;
	for (int i=1;i<=n;i++) cin>>x[i];
	for (int i=1;i<=n;i++) cin>>v[i];

	double ans=bsearch((double)1,(double)1e9);

	double myans=1e9;

	for (int i=1;i<=n;i++) {
		myans=min(myans,time(ans));
	}

	printf("%.9f",myans);

	return 0;

}


#define ll long long

#include <iostream>
#include <stdlib.h>
#include <string>
#include <algorithm>
#include <math.h>
#include <cstring>
#include <sstream>
#include <vector>
#include <map>
#include <set>
#include <queue>
#include <time.h>
#include <stack>

using namespace std;

const double DELTA=1e-7;

int n;
double x[1000000];
double v[1000000];

double time(double pos) {

	double ans=0;

	for (int i=1;i<=n;i++) ans=max(ans,max(pos-x[i],x[i]-pos)/v[i]);

	return ans;

}

double bsearch(double s, double e) {

	if (e-s<1) {
		for (double x=s;x<=e;x+=DELTA) {
			if (time(x)<time(x+DELTA)) return x;
		}
		return e+DELTA;
	}

	double mid=(s+e)/2;
//	cout<<mid<<endl;

	if (time(mid)<time(mid+DELTA)) return bsearch(s,mid);
	else return bsearch(mid,e);

}

int main() {

	ios_base::sync_with_stdio(false);

	cin>>n;
	for (int i=1;i<=n;i++) cin>>x[i];
	for (int i=1;i<=n;i++) cin>>v[i];

	double ans=bsearch((double)1,(double)1e9);

	double myans=1e9;

	for (int i=1;i<=n;i++) {
		myans=min(myans,time(ans));
	}

	printf("%.9f",myans);

	return 0;

}


#include<bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <bitset>
using namespace std;
using namespace __gnu_pbds;
#pragma GCC optimization("Ofast")
#pragma GCC optimization("unroll-loops")
#pragma GCC target ("avx2,avx,fma")
typedef long long int ll;
//#define int long long int
typedef pair <int,int> ii ;
typedef vector < ii > vii ;
typedef vector < vii > viii ;
#define rep(i,n)                   for(int i = 0 ; i < n ; i++)
#define repu(i,a,b)                for(int i = a ; i <= b ; i++)
#define repd(i,b,a)                for(int i = b ; i >= a ; i--)
#define pb push_back
#define fi first
#define se second
#define all(p)                p.begin(),p.end()
#define IOS                           \
    std::ios::sync_with_stdio(false); \
    cin.tie(NULL);                    \
    cout.tie(NULL);
#define endl "\n"
#define Endl endl
template <class T>inline void sary(T* st, T* nd){while(st<nd)cin>>*st++;/*sf("%d", st++);*/}
#define pi 3.1415926535897932384626433832
const int mod = 998244353;

bool solve(double mid, vector<ii> v, int n) {
  double ma=DBL_MIN, mi=DBL_MAX;
  rep(i,n) {
    ma=max(ma,v[i].fi-mid*v[i].se);
    mi=min(mi,v[i].fi+mid*v[i].se);
  }
  return ma<=mi;
}

void calc() {
  int n; cin>>n;
  vector<ii> v(n);
  rep(i,n) cin>>v[i].fi;
  rep(i,n) cin>>v[i].se;
  sort(all(v));
  double low=0, high=1e9, ans;
  while(low<high) {
    double mid=0.500000000*(low+high);
    if(solve(mid,v,n)) {
      high=mid; ans=mid;
    } else low=mid;
    //cout<<fixed<<low<<" "<<high<<" "<<(low==high);
    if(abs(low-high)<=0.0000001) break;
  }
  cout<<fixed<<setprecision(6)<<ans;
}

int32_t main() {
  IOS
  int t;
  t=1;
  //cin>>t;
  while(t--) calc();
}


#include<bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <bitset>
using namespace std;
using namespace __gnu_pbds;
#pragma GCC optimization("Ofast")
#pragma GCC optimization("unroll-loops")
#pragma GCC target ("avx2,avx,fma")
typedef long long int ll;
//#define int long long int
typedef pair <int,int> ii ;
typedef vector < ii > vii ;
typedef vector < vii > viii ;
#define rep(i,n)                   for(int i = 0 ; i < n ; i++)
#define repu(i,a,b)                for(int i = a ; i <= b ; i++)
#define repd(i,b,a)                for(int i = b ; i >= a ; i--)
#define pb push_back
#define fi first
#define se second
#define all(p)                p.begin(),p.end()
#define IOS                           \
    std::ios::sync_with_stdio(false); \
    cin.tie(NULL);                    \
    cout.tie(NULL);
#define endl "\n"
#define Endl endl
template <class T>inline void sary(T* st, T* nd){while(st<nd)cin>>*st++;/*sf("%d", st++);*/}
#define pi 3.1415926535897932384626433832
const int mod = 998244353;

bool solve(double mid, vector<ii> v, int n) {
  double ma=DBL_MIN, mi=DBL_MAX;
  rep(i,n) {
    ma=max(ma,v[i].fi-mid*v[i].se);
    mi=min(mi,v[i].fi+mid*v[i].se);
  }
  return ma<=mi;
}

void calc() {
  int n; cin>>n;
  vector<ii> v(n);
  rep(i,n) cin>>v[i].fi;
  rep(i,n) cin>>v[i].se;
  sort(all(v));
  double low=0, high=1e9, ans;
  while(low<high) {
    double mid=0.500000000*(low+high);
    if(solve(mid,v,n)) {
      high=mid; ans=mid;
    } else low=mid;
    //cout<<fixed<<low<<" "<<high<<" "<<(low==high);
    if(abs(low-high)<=0.00000001) break;
  }
  cout<<fixed<<setprecision(6)<<ans;
}

int32_t main() {
  IOS
  int t;
  t=1;
  //cin>>t;
  while(t--) calc();
}


#include<bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <bitset>
using namespace std;
using namespace __gnu_pbds;
#pragma GCC optimization("Ofast")
#pragma GCC optimization("unroll-loops")
#pragma GCC target ("avx2,avx,fma")
typedef long long int ll;
//#define int long long int
typedef pair <int,int> ii ;
typedef vector < ii > vii ;
typedef vector < vii > viii ;
#define rep(i,n)                   for(int i = 0 ; i < n ; i++)
#define repu(i,a,b)                for(int i = a ; i <= b ; i++)
#define repd(i,b,a)                for(int i = b ; i >= a ; i--)
#define pb push_back
#define fi first
#define se second
#define all(p)                p.begin(),p.end()
#define IOS                           \
    std::ios::sync_with_stdio(false); \
    cin.tie(NULL);                    \
    cout.tie(NULL);
#define endl "\n"
#define Endl endl
template <class T>inline void sary(T* st, T* nd){while(st<nd)cin>>*st++;/*sf("%d", st++);*/}
#define pi 3.1415926535897932384626433832
const int mod = 998244353;

bool solve(double mid, vector<ii> v, int n) {
  double ma=DBL_MIN, mi=DBL_MAX;
  rep(i,n) {
    ma=max(ma,v[i].fi-mid*v[i].se);
    mi=min(mi,v[i].fi+mid*v[i].se);
  }
  return ma<=mi;
}

void calc() {
  int n; cin>>n;
  vector<ii> v(n);
  rep(i,n) cin>>v[i].fi;
  rep(i,n) cin>>v[i].se;
  sort(all(v));
  double low=0, high=1e9, ans;
  while(low<high) {
    double mid=0.500000000*(low+high);
    if(solve(mid,v,n)) {
      high=mid; ans=mid;
    } else low=mid;
    //cout<<fixed<<low<<" "<<high<<" "<<(low==high);
    if(abs(low-high)<=0.000001) break;
  }
  cout<<fixed<<ans;
}

int32_t main() {
  IOS
  int t;
  t=1;
  //cin>>t;
  while(t--) calc();
}


#include<bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <bitset>
using namespace std;
using namespace __gnu_pbds;
#pragma GCC optimization("Ofast")
#pragma GCC optimization("unroll-loops")
#pragma GCC target ("avx2,avx,fma")
typedef long long int ll;
//#define int long long int
typedef pair <int,int> ii ;
typedef vector < ii > vii ;
typedef vector < vii > viii ;
#define rep(i,n)                   for(int i = 0 ; i < n ; i++)
#define repu(i,a,b)                for(int i = a ; i <= b ; i++)
#define repd(i,b,a)                for(int i = b ; i >= a ; i--)
#define pb push_back
#define fi first
#define se second
#define all(p)                p.begin(),p.end()
#define IOS                           \
    std::ios::sync_with_stdio(false); \
    cin.tie(NULL);                    \
    cout.tie(NULL);
#define endl "\n"
#define Endl endl
template <class T>inline void sary(T* st, T* nd){while(st<nd)cin>>*st++;/*sf("%d", st++);*/}
#define pi 3.1415926535897932384626433832
const int mod = 998244353;

bool solve(double mid, vector<ii> v, int n) {
  double ma=DBL_MIN, mi=DBL_MAX;
  rep(i,n) {
    ma=max(ma,v[i].fi-mid*v[i].se);
    mi=min(mi,v[i].fi+mid*v[i].se);
  }
  return ma<=mi;
}

void calc() {
  int n; cin>>n;
  vector<ii> v(n);
  rep(i,n) cin>>v[i].fi;
  rep(i,n) cin>>v[i].se;
  sort(all(v));
  double low=0, high=1e9, ans;
  while(low<high) {
    double mid=(low+high)/2;
    if(solve(mid,v,n)) {
      high=mid; ans=mid;
    } else low=mid;
    //cout<<fixed<<low<<" "<<high<<" "<<(low==high);
    if(abs(low-high)<=0.000001) break;
  }
  cout<<ans;
}

int32_t main() {
  IOS
  int t;
  t=1;
  //cin>>t;
  while(t--) calc();
}


#include<bits/stdc++.h>
using namespace std;
bool f(vector<pair<long,long> >v,double time)
{
    double temp=99999999999;
    for(int i=0;i<=v.size()/2;i++)
    {
        temp=min((double)(v[i].first+(double)(v[i].second*time)),temp);
      // printf("%.8f\n",(double)(v[i].second));
    }

    double temp1=-999999999999;
    for(int i=v.size()-1;i>v.size()/2;i--)
    {
        temp1=max((double)(v[i].first-(double)(v[i].second*time)),temp1);
        //printf("%.8f\n",temp1);
    }
    if(temp1-temp<=0)
        return 1;
    else
        return 0;
}
int main()
{
   int n;
   long x,y;
   cin>>n;
   vector<pair<long,long> >v;
   long a[n],b[n];
   for(int i=0;i<n;i++)
   {
       cin>>a[i];
   }
    for(int i=0;i<n;i++)
   {
       cin>>b[i];
       v.push_back(make_pair(a[i],b[i]));
   }

   sort(v.begin(),v.end());
   double cc=1*pow(10,-6);
   double s=0,ans;
   double e=1*pow(10,9);
   while(s<=e)
   {
       double mid=(s+e)/2;
       if(f(v,mid)==1)
       {
           printf("%.8f\n",mid);
           ans=mid;
           e=mid-cc;
       }
       else
       {
           s=mid+cc;
       }
        //printf("%.8f\n",mid);
   }
   printf("%.8f",ans);
  // cout<<f(v,333333332.999999999971);
}


#include<bits/stdc++.h>
using namespace std;
bool f(vector<pair<long,long> >v,double time)
{
    double temp=999999;
    for(int i=0;i<=v.size()/2;i++)
    {
        temp=min((double)(v[i].first+(double)(v[i].second*time)),temp);
       //printf("%.8f\n",(double)(v[i].second));
    }

    double temp1=-999999;
    for(int i=v.size()-1;i>v.size()/2;i--)
    {
        temp1=max((double)(v[i].first-(double)(v[i].second*time)),temp1);
       // printf("%.8f\n",temp1);
    }
    if(temp1-temp<=0)
        return 1;
    else
        return 0;
}
int main()
{
   int n;
   long x,y;
   cin>>n;
   vector<pair<long,long> >v;
   long a[n],b[n];
   for(int i=0;i<n;i++)
   {
       cin>>a[i];
   }
    for(int i=0;i<n;i++)
   {
       cin>>b[i];
       v.push_back(make_pair(a[i],b[i]));
   }

   sort(v.begin(),v.end());
   double cc=1*pow(10,-6);
   double s=0,ans;
   double e=1*pow(10,9);
   while(s<=e)
   {
       double mid=(s+e)/2;
       if(f(v,mid)==1)
       {
           ans=mid;
           e=mid-cc;
       }
       else
       {
           s=mid+cc;
       }
        //printf("%.8f\n",mid);
   }
   printf("%.8f",ans);
   //cout<<f(v,2.000000000);
}


#include<bits/stdc++.h>
using namespace std;
bool f(vector<pair<long,long> >v,double time)
{
    double temp=99999999999;
    for(int i=0;i<v.size()/2;i++)
    {
        temp=min((double)(v[i].first+(double)(v[i].second*time)),temp);
        //printf("%.8f\n",temp);
    }
    double temp1=-999999999999;
    for(int i=v.size()-1;i>=v.size()/2;i--)
    {
        temp1=max((double)(v[i].first-(double)(v[i].second*time)),temp1);
        //printf("%.8f\n",temp1);
    }
    if(temp1-temp<=0)
        return 1;
    else
        return 0;
}
int main()
{
   int n;
   long x,y;
   cin>>n;
   vector<pair<long,long> >v;
   long a[n],b[n];
   for(int i=0;i<n;i++)
   {
       cin>>a[i];
   }
    for(int i=0;i<n;i++)
   {
       cin>>b[i];
       v.push_back(make_pair(a[i],b[i]));
   }

   sort(v.begin(),v.end());
   double cc=1*pow(10,-6);
   double s=0,ans;
   double e=1*pow(10,9);
   while(s<=e)
   {
       double mid=(s+e)/2;
       if(f(v,mid)==1)
       {
           //printf("%.8f\n",mid);
           ans=mid;
           e=mid-cc;
       }
       else
       {
           s=mid+cc;
       }
        //printf("%.8f\n",mid);
   }
   printf("%.8f",ans);
  //cout<<f(v,0.00000078);
}


#include<bits/stdc++.h>
using namespace std;
bool f(vector<pair<long,long> >v,double time)
{
    double temp=99999999999;
    for(int i=0;i<=v.size()/2;i++)
    {
        temp=min((double)(v[i].first+(double)(v[i].second*time)),temp);
      // printf("%.8f\n",(double)(v[i].second));
    }

    double temp1=-999999999999;
    for(int i=v.size()-1;i>v.size()/2;i--)
    {
        temp1=max((double)(v[i].first-(double)(v[i].second*time)),temp1);
        //printf("%.8f\n",temp1);
    }
    if(temp1-temp<=0)
        return 1;
    else
        return 0;
}
int main()
{
   int n;
   long x,y;
   cin>>n;
   vector<pair<long,long> >v;
   long a[n],b[n];
   for(int i=0;i<n;i++)
   {
       cin>>a[i];
   }
    for(int i=0;i<n;i++)
   {
       cin>>b[i];
       v.push_back(make_pair(a[i],b[i]));
   }

   sort(v.begin(),v.end());
   double cc=1*pow(10,-6);
   double s=0,ans;
   double e=1*pow(10,9);
   while(s<=e)
   {
       double mid=(s+e)/2;
       if(f(v,mid)==1)
       {
           //printf("%.8f\n",mid);
           ans=mid;
           e=mid-cc;
       }
       else
       {
           s=mid+cc;
       }
        //printf("%.8f\n",mid);
   }
   printf("%.8f",ans);
  // cout<<f(v,333333332.999999999971);
}


#include <iostream>
#include <bits/stdc++.h>
#define ll long long int
using namespace std;
#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma")
// the little guy below helps me to create unordered set of vectors
// just declare it like this ---> unordered_set<vector<int>, VectorHash>>
// credits:: https://stackoverflow.com/users/2069064/barry
struct VectorHash
{
    size_t operator()(const std::vector<int> &v) const
    {
        std::hash<int> hasher;
        size_t seed = 0;
        for (int i : v)
        {
            seed ^= hasher(i) + 0x9e3779b9 + (seed << 6) + (seed >> 2);
        }
        return seed;
    }
};
void __print(int x) { cerr << x; }
void __print(long x) { cerr << x; }
void __print(long long x) { cerr << x; }
void __print(unsigned x) { cerr << x; }
void __print(unsigned long x) { cerr << x; }
void __print(unsigned long long x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define debug(x...)               \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define debug(x...)
#endif
vector<double> x,v;
ll n;

bool check(double time)
{
    double l = -1000000000;
    double r = 1000000000;
    for (int i = 0; i<n; i++)
    {
        l = max(l,  x[i] - time * v[i]);
        r = min(r, x[i] + time * v[i]);
        if (l>r)
            return 0;
    }
    return 1;
}

int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    ll z;
    cin >> n;
    for (int i = 0; i < n; i++)
        cin >> z, x.push_back(z);
   // cout << x[i] << " ";
    for (int i = 0; i < n; i++)
        cin >> z, v.push_back(z);
    ll k = 1000;
    double l = 1;
    double r = 1000000000;
    double ans ;
    while (k--)
    {
        double mid = (r - l) / 2.0 + l;
        if (check(mid))
        {
            ans =  mid;
            r = mid ;
        }
        else
        {
            l = mid ;
        }
        //cout << fixed << setprecision(7) << mid << '\n';
    }
    cout << fixed << setprecision(6) << ans;
    // for (int i = 1; i < 4; i++)
    // {
    //     cout << check(i) << '\n';
    // }
}


#include <iostream>
#include <bits/stdc++.h>
#define ll long long int
using namespace std;
#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma")
// the little guy below helps me to create unordered set of vectors
// just declare it like this ---> unordered_set<vector<int>, VectorHash>>
// credits:: https://stackoverflow.com/users/2069064/barry
struct VectorHash
{
    size_t operator()(const std::vector<int> &v) const
    {
        std::hash<int> hasher;
        size_t seed = 0;
        for (int i : v)
        {
            seed ^= hasher(i) + 0x9e3779b9 + (seed << 6) + (seed >> 2);
        }
        return seed;
    }
};
void __print(int x) { cerr << x; }
void __print(long x) { cerr << x; }
void __print(long long x) { cerr << x; }
void __print(unsigned x) { cerr << x; }
void __print(unsigned long x) { cerr << x; }
void __print(unsigned long long x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define debug(x...)               \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define debug(x...)
#endif
vector<double> x,v;
ll n;

bool check(double time)
{
    double l = -1000000000;
    double r = 1000000000;
    for (int i = 0; i<n; i++)
    {
        l = max(l,  x[i] - time * v[i]);
        r = min(r, x[i] + time * v[i]);
        if (l>r)
            return 0;
    }
    return 1;
}

int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    ll z;
    cin >> n;
    for (int i = 0; i < n; i++)
        cin >> z, x.push_back(z);
   // cout << x[i] << " ";
    for (int i = 0; i < n; i++)
        cin >> z, v.push_back(z);
    ll k = 500;
    double l = 1;
    double r = 1000000000;
    double ans ;
    while (k--)
    {
        double mid = (r - l) / 2.0 + l;
        if (check(mid))
        {
            ans =  mid;
            r = mid ;
        }
        else
        {
            l = mid ;
        }
        //cout << fixed << setprecision(7) << mid << '\n';
    }
    cout << fixed << setprecision(7) << ans;
    // for (int i = 1; i < 4; i++)
    // {
    //     cout << check(i) << '\n';
    // }
}


#include <iostream>
#include <bits/stdc++.h>
#define ll long long int
using namespace std;
#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma")
// the little guy below helps me to create unordered set of vectors
// just declare it like this ---> unordered_set<vector<int>, VectorHash>>
// credits:: https://stackoverflow.com/users/2069064/barry
struct VectorHash
{
    size_t operator()(const std::vector<int> &v) const
    {
        std::hash<int> hasher;
        size_t seed = 0;
        for (int i : v)
        {
            seed ^= hasher(i) + 0x9e3779b9 + (seed << 6) + (seed >> 2);
        }
        return seed;
    }
};
void __print(int x) { cerr << x; }
void __print(long x) { cerr << x; }
void __print(long long x) { cerr << x; }
void __print(unsigned x) { cerr << x; }
void __print(unsigned long x) { cerr << x; }
void __print(unsigned long long x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define debug(x...)               \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define debug(x...)
#endif
vector<double> x,v;
ll n;

bool check(double time)
{
    double l = -1000000000;
    double r = 1000000000;
    for (int i = 0; i<n; i++)
    {
        l = max(l,  x[i] - time * v[i]);
        r = min(r, x[i] + time * v[i]);
        if (l>r)
            return 0;
    }
    return 1;
}

int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    ll z;
    cin >> n;
    for (int i = 0; i < n; i++)
        cin >> z, x.push_back(z);
   // cout << x[i] << " ";
    for (int i = 0; i < n; i++)
        cin >> z, v.push_back(z);
    ll k = 60;
    double l = 0;
    double r = 1000000000;
    double ans ;
    while (k--)
    {
        double mid = (r - l) / 2.0 + l;
        if (check(mid))
        {
            ans =  mid;
            r = mid ;
        }
        else
        {
            l = mid ;
        }
        //cout << fixed << setprecision(7) << mid << '\n';
    }
    cout << fixed << setprecision(6) << ans;
    // for (int i = 1; i < 4; i++)
    // {
    //     cout << check(i) << '\n';
    // }
}


#include <iostream>
#include <bits/stdc++.h>
#define ll long long int
using namespace std;
#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma")
// the little guy below helps me to create unordered set of vectors
// just declare it like this ---> unordered_set<vector<int>, VectorHash>>
// credits:: https://stackoverflow.com/users/2069064/barry
struct VectorHash
{
    size_t operator()(const std::vector<int> &v) const
    {
        std::hash<int> hasher;
        size_t seed = 0;
        for (int i : v)
        {
            seed ^= hasher(i) + 0x9e3779b9 + (seed << 6) + (seed >> 2);
        }
        return seed;
    }
};
void __print(int x) { cerr << x; }
void __print(long x) { cerr << x; }
void __print(long long x) { cerr << x; }
void __print(unsigned x) { cerr << x; }
void __print(unsigned long x) { cerr << x; }
void __print(unsigned long long x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define debug(x...)               \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define debug(x...)
#endif
vector<double> x,v;
ll n;

bool check(double time)
{
    double l = -1000000000;
    double r = 1000000000;
    for (int i = 0; i<n; i++)
    {
        l = max(l,  x[i] - time * v[i]);
        r = min(r, x[i] + time * v[i]);
        if (l>r)
            return 0;
    }
    return 1;
}

int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    ll z;
    cin >> n;
    for (int i = 0; i < n; i++)
        cin >> z, x.push_back(z);
   // cout << x[i] << " ";
    for (int i = 0; i < n; i++)
        cin >> z, v.push_back(z);
    ll k = 60;
    double l = 0;
    double r = 1000000000;
    double ans ;
    while (abs(r-l)>1e-6)
    {
        double mid = (r - l) / 2.0 + l;
        if (check(mid))
        {
            ans =  mid;
            r = mid ;
        }
        else
        {
            l = mid ;
        }
        //cout << fixed << setprecision(7) << mid << '\n';
    }
    cout << fixed << setprecision(6) << ans;
    // for (int i = 1; i < 4; i++)
    // {
    //     cout << check(i) << '\n';
    // }
}


#include <iostream>
#include <bits/stdc++.h>
#define ll long long int
using namespace std;
#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma")
// the little guy below helps me to create unordered set of vectors
// just declare it like this ---> unordered_set<vector<int>, VectorHash>>
// credits:: https://stackoverflow.com/users/2069064/barry
struct VectorHash
{
    size_t operator()(const std::vector<int> &v) const
    {
        std::hash<int> hasher;
        size_t seed = 0;
        for (int i : v)
        {
            seed ^= hasher(i) + 0x9e3779b9 + (seed << 6) + (seed >> 2);
        }
        return seed;
    }
};
void __print(int x) { cerr << x; }
void __print(long x) { cerr << x; }
void __print(long long x) { cerr << x; }
void __print(unsigned x) { cerr << x; }
void __print(unsigned long x) { cerr << x; }
void __print(unsigned long long x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define debug(x...)               \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define debug(x...)
#endif
vector<double> x,v;
ll n;

bool check(double time)
{
    double l = -1000000000;
    double r = 1000000000;
    for (int i = 0; i<n; i++)
    {
        l = max(l,  x[i] - time * v[i]);
        r = min(r, x[i] + time * v[i]);
        if (l>r)
            return 0;
    }
    return 1;
}

int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    ll z;
    cin >> n;
    for (int i = 0; i < n; i++)
        cin >> z, x.push_back(z);
   // cout << x[i] << " ";
    for (int i = 0; i < n; i++)
        cin >> z, v.push_back(z);
    ll k = 1000;
    double l = 0;
    double r = 1000000000;
    double ans ;
    while (k--)
    {
        double mid = (r - l) / 2.0 + l;
        if (check(mid))
        {
            ans =  mid;
            r = mid ;
        }
        else
        {
            l = mid ;
        }
        //cout << fixed << setprecision(7) << mid << '\n';
    }
    cout << fixed << setprecision(6) << ans;
    // for (int i = 1; i < 4; i++)
    // {
    //     cout << check(i) << '\n';
    // }
}


#include <iostream>
#include <bits/stdc++.h>
#define ll long long int
using namespace std;
#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma")
// the little guy below helps me to create unordered set of vectors
// just declare it like this ---> unordered_set<vector<int>, VectorHash>>
// credits:: https://stackoverflow.com/users/2069064/barry
struct VectorHash
{
    size_t operator()(const std::vector<int> &v) const
    {
        std::hash<int> hasher;
        size_t seed = 0;
        for (int i : v)
        {
            seed ^= hasher(i) + 0x9e3779b9 + (seed << 6) + (seed >> 2);
        }
        return seed;
    }
};
void __print(int x) { cerr << x; }
void __print(long x) { cerr << x; }
void __print(long long x) { cerr << x; }
void __print(unsigned x) { cerr << x; }
void __print(unsigned long x) { cerr << x; }
void __print(unsigned long long x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define debug(x...)               \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define debug(x...)
#endif
vector<double> x,v;
ll n;

bool check(double time)
{
    double l = -1000000000;
    double r = 1000000000;
    for (int i = 0; i<n; i++)
    {
        l = max(l,  x[i] - time * v[i]);
        r = min(r, x[i] + time * v[i]);
        if (l>r)
            return 0;
    }
    return 1;
}

int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    ll z;
    cin >> n;
    for (int i = 0; i < n; i++)
        cin >> z, x.push_back(z);
   // cout << x[i] << " ";
    for (int i = 0; i < n; i++)
        cin >> z, v.push_back(z);
    ll k = 50;
    double l = 0;
    double r = 1000000000;
    double ans ;
    while (k--)
    {
        double mid = (r - l) / 2.0 + l;
        if (check(mid))
        {
            ans =  mid;
            r = mid ;
        }
        else
        {
            l = mid ;
        }
        //cout << fixed << setprecision(7) << mid << '\n';
    }
    cout << fixed << setprecision(6) << ans;
    // for (int i = 1; i < 4; i++)
    // {
    //     cout << check(i) << '\n';
    // }
}


#include <iostream>
#include <bits/stdc++.h>
#define ll long long int
using namespace std;
#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma")
// the little guy below helps me to create unordered set of vectors
// just declare it like this ---> unordered_set<vector<int>, VectorHash>>
// credits:: https://stackoverflow.com/users/2069064/barry
struct VectorHash
{
    size_t operator()(const std::vector<int> &v) const
    {
        std::hash<int> hasher;
        size_t seed = 0;
        for (int i : v)
        {
            seed ^= hasher(i) + 0x9e3779b9 + (seed << 6) + (seed >> 2);
        }
        return seed;
    }
};
void __print(int x) { cerr << x; }
void __print(long x) { cerr << x; }
void __print(long long x) { cerr << x; }
void __print(unsigned x) { cerr << x; }
void __print(unsigned long x) { cerr << x; }
void __print(unsigned long long x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define debug(x...)               \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define debug(x...)
#endif
vector<double> x,v;
ll n;

bool check(double time)
{
    double l = -1000000000;
    double r = 1000000000;
    for (int i = 0; i<n; i++)
    {
        l = max(l,  x[i] - time * v[i]);
        r = min(r, x[i] + time * v[i]);
        if (l>r)
            return 0;
    }
    return 1;
}

int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    ll z;
    cin >> n;
    for (int i = 0; i < n; i++)
        cin >> z, x.push_back(z);
   // cout << x[i] << " ";
    for (int i = 0; i < n; i++)
        cin >> z, v.push_back(z);
    ll k = 60;
    double l = 0;
    double r = 1000000000;
    double ans ;
    while (abs(r-l)>1e-7)
    {
        double mid = (r - l) / 2.0 + l;
        if (check(mid))
        {
            ans =  mid;
            r = mid ;
        }
        else
        {
            l = mid ;
        }
        //cout << fixed << setprecision(7) << mid << '\n';
    }
    cout << fixed << setprecision(6) << ans;
    // for (int i = 1; i < 4; i++)
    // {
    //     cout << check(i) << '\n';
    // }
}


#include <iostream>
#include <bits/stdc++.h>
#define ll long long int
using namespace std;
#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma")
// the little guy below helps me to create unordered set of vectors
// just declare it like this ---> unordered_set<vector<int>, VectorHash>>
// credits:: https://stackoverflow.com/users/2069064/barry
struct VectorHash
{
    size_t operator()(const std::vector<int> &v) const
    {
        std::hash<int> hasher;
        size_t seed = 0;
        for (int i : v)
        {
            seed ^= hasher(i) + 0x9e3779b9 + (seed << 6) + (seed >> 2);
        }
        return seed;
    }
};
void __print(int x) { cerr << x; }
void __print(long x) { cerr << x; }
void __print(long long x) { cerr << x; }
void __print(unsigned x) { cerr << x; }
void __print(unsigned long x) { cerr << x; }
void __print(unsigned long long x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define debug(x...)               \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define debug(x...)
#endif
vector<double> x,v;
ll n;

bool check(double time)
{
    double l = -1000000000;
    double r = 1000000000;
    for (int i = 0; i<n; i++)
    {
        l = max(l,  x[i] - time * v[i]);
        r = min(r, x[i] + time * v[i]);
        if (l>r)
            return 0;
    }
    return 1;
}

int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    ll z;
    cin >> n;
    for (int i = 0; i < n; i++)
        cin >> z, x.push_back(z);
   // cout << x[i] << " ";
    for (int i = 0; i < n; i++)
        cin >> z, v.push_back(z);
    ll k = 1000;
    double l = 1;
    double r = 1000000000;
    double ans ;
    while (k--)
    {
        double mid = (r - l) / 2.0 + l;
        if (check(mid))
        {
            ans =  mid;
            r = mid ;
        }
        else
        {
            l = mid ;
        }
        //cout << fixed << setprecision(7) << mid << '\n';
    }
    cout << fixed << setprecision(7) << ans;
    // for (int i = 1; i < 4; i++)
    // {
    //     cout << check(i) << '\n';
    // }
}


#include <iostream>
#include <stdio.h>
using namespace std;
const long double EPS = 1e-12;
int main()
{
    int n;
    cin >> n;
    double x[60000], v[60000];
    for(int i = 0; i < n; i++)
        cin >> x[i];
    for(int i = 0; i < n; i++)
        cin >> v[i];
    double l = 0, r = 2e9 + 1, mid;
    double mins, maxs;
    //for(int j = 0; j < 500; j++){
    while(r - l > EPS){
        mid = (l + r) / 2; //mid = t;
        mins = 1e9;
        maxs = -1e9;
		for(int i = 0; i < n; i++){
			mins = min(mins, x[i] + v[i] * mid);
			maxs = max(maxs, x[i] - v[i] * mid);
		}
        if(mins < maxs)
            l = mid;
        else
            r = mid;
    }
    printf("%.12f\n", mid);
    return 0;
}


#include <iostream>
#include <stdio.h>
using namespace std;
const long double EPS = 1e-7;
int main()
{
    int n;
    cin >> n;
    double x[60000], v[60000];
    for(int i = 0; i < n; i++)
        cin >> x[i];
    for(int i = 0; i < n; i++)
        cin >> v[i];
    double l = 0, r = 2e9 + 1, mid;
    double mins, maxs;
    //for(int j = 0; j < 500; j++){
    while(r - l > EPS){
        mid = (l + r) / 2; //mid = t;
        mins = 1e9;
        maxs = -1e9;
		for(int i = 0; i < n; i++){
			mins = min(mins, x[i] + v[i] * mid);
			maxs = max(maxs, x[i] - v[i] * mid);
		}
        if(mins < maxs)
            l = mid;
        else
            r = mid;
    }
    printf("%.12f\n", mid);
    return 0;
}


/*                                 ___ _____
  ___  _ __ ___   ___  __ _  __ _ / _ \___  |
 / _ \| '_ ` _ \ / _ \/ _` |/ _` | | | | / /
| (_) | | | | | |  __/ (_| | (_| | |_| |/ /
 \___/|_| |_| |_|\___|\__, |\__,_|\___//_/
                      |___/
*/
// Getting better at it ! ! !
#include <bits/stdc++.h>
#include <string.h>
#define int long long
#define MAX (int)(1e7+5)
#define MAX2D (int)(1e3+5)
#define itn int
#define inf 5e18
#define MOD (int)(1e9 + 7)
#define pb push_back
#define mk make_pair
#define all(x) x.begin(), x.end()
#define rall(x) x.rbegin(),x.rend()
#define sitr set<int>::iterator
#define mitr map<int, int>::iterator
#define pii pair<int, int>
#define vii vector<pii>
#define vi vector<int>
#define vll vector<unsigned int>
#define test  \
    int t;    \
    cin >> t; \
    while (t--)
#define fast                       \
    ios_base ::sync_with_stdio(0); \
    cin.tie(NULL);                 \
    cout.tie(NULL)
using namespace std;

void __print(int x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define see(x...)                 \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define see(x...)
#endif
/*
int a[(int)MAX];
vi v;
void sieve(int max = (int)1e7) {
    for(int i=0;i<=max;i++) a[i] = 1;
    a[0] = a[1] = 0;
    for(int i=2;i<=(int)sqrt(max);i++) {
        if(a[i] == 1) {
            for(int j=i*i;j<=max;j+=i) a[j] = 0;
            v.pb(i);
        }
    }
    for(int i=(int)sqrt(max)+1;i<=max;i++) {
        if(a[i] == 1) v.pb(i);
    }
}

int SPF[(int)MAX];
void spf(int max = (int)1e7) {
    for(int i=0;i<=max;i++) SPF[i] = 1;
    SPF[0] = SPF[1] = 0;
    for(int i=2;i<=sqrt(max);i++) {
        if(SPF[i] == 1) {
            for(int j = i;j<=max;j+=i) if(SPF[j] == 1) SPF[j] = i;
        }
    }
    for(int i=sqrt(max)+1;i<=max;i++) if(SPF[i] == 1) SPF[i] = i;
}
*/

//calculate factorial...
//vi f(MAX); void fact(int max = (int)1e7){f[0] = 1, f[1] = 1;for (int i = 2; i <= max; i++)f[i] = (i * f[i - 1]) % MOD;}

//int nCrMODm(int n, int r, int m = MOD){fact();if(r == 0) return 1; int x = f[n], y = f[n - r], z = f[r]; return (x * mod__inverse(y) % m * mod__inverse(z) % m + m) % m;}
//int I_fpow(int x,int y,int p = MOD){int res = 1;x = x % p;while (y > 0){if (y & 1) res = (res * x) % p;y = y >> 1;x = (x * x) % p;} return res;}

//int palindrome (string s){int x; if(!(s.length()%2)) x = s.length()/2 - 1; else x = s.length()/2; for(int i=0;i<=x;i++) {if(s[i] != s[s.length()-1-i]) return 0; } return 1; }
//int palindrome (int n){int x;string s = tostring(n); if(!(s.length()%2)) x = s.length()/2 - 1; else x = s.length()/2; for(int i=0;i<=x;i++) {if(s[i] != s[s.length()-1-i]) return 0; } return 1; }
//int toint(const string &s) {stringstream ss; ss << s; int x; ss >> x; return x;}
//string tostring ( int number ){stringstream ss; ss<< number; return ss.str();}
// Addition of 2 strings ... based on the addition performed with the help of carry.
//string add2strings(string s1,string s2){if(s1.length()>s2.length())swap(s1,s2);int n = s1.length();int m = s2.length();int carry = 0;reverse(all(s1));reverse(all(s2));string ans = "";for(int i=0;i<n;i++){int sum = (char)(s1[i]-'0')+(char)(s2[i]-'0')+carry;ans += (char)(sum%10 + '0');carry = sum/10;}for(int i=n;i<m;i++){int sum = (char)(s2[i]-'0')+carry;ans += (char)(sum%10 + '0');carry = sum/10;}if(carry)ans += (char)(carry+'0');reverse(all(ans));return ans;}

//key to euclids extended --> gcd(a,b) = gcd(b,a%b)
//also a%b = a-(a/b)*b;
//hence ax+by = bx1+(a%b)y1.. ax+by = bx1+(ay1-(a/b)*by1)..
//comparing x = y1;
//y = x1-(a/b)*y1
//void extendedEuclid(int a,int b,int &x,int &y){int res;if(b == 0){res = a;x = 1;y = 0;}else{extendedEuclid(b,a%b,x,y);int t = x;x = y;y = t - (a/b)*x;}}

//if m is prime fermats little theorem can be used
//int modInverse(int a,int m){return I_fpow(a,m-2);}

//if not
//In extendedGCD x is the mod mult inverse of a under b and y is the mod mult inverse of b under a
//Inverse exist if a,m is co-prime
//int mod__Inverse(int a,int m){int x,y;extendedEuclid(a,m,x,y); return (x%m+m)%m;}
//int rr[] = {-1,0,1,0};
//int cc[] = {0,1,0,-1};

double eps = 0.000001;
vector<double> x(MAX), v(MAX);
int n;
bool good(double g) {
    vector<pair<double,double>> pos;
    for(int i=0;i<n;i++) {
        double l_lim = x[i]-v[i]*g;
        double r_lim = x[i]+v[i]*g;
        pos.pb({l_lim,r_lim});
    }
    double lx = 0, rx = inf;
    for(int i=0;i<n;i++) {
        lx = max(lx,pos[i].first), rx = min(rx,pos[i].second);
    }
    if(rx-lx > 0) return true;
    return false;
}

double f() {
    double l = 0.0f, r = 1e9f;
    double ans = l;
    for(int i=0;i<100 && l+eps < r;i++) {
        double mid = 0.5f*(l+r);
        if(good(mid)) {
            ans = mid, r = mid;
        }
        else l = mid;
    }
    return ans;
}

signed main()
{
    fast;
    cin>>n;
    for(int i=0;i<n;i++) cin>>x[i];
    for(int i=0;i<n;i++) cin>>v[i];
    cout<<f();
    return 0;
}

/*
max factors number = 720720 --> 240 factors
max factors number = 1441440 -->288 factors

Beautiful program
Please run for me.
I've tried you in BASIC,
FORTRAN and C.
Beautiful program,
You've errors galore.
And each time I run you,
You're swapped out of core.
*/


/*                                 ___ _____
  ___  _ __ ___   ___  __ _  __ _ / _ \___  |
 / _ \| '_ ` _ \ / _ \/ _` |/ _` | | | | / /
| (_) | | | | | |  __/ (_| | (_| | |_| |/ /
 \___/|_| |_| |_|\___|\__, |\__,_|\___//_/
                      |___/
*/
// Getting better at it ! ! !
#include <bits/stdc++.h>
#include <string.h>
#define int long long
#define MAX (int)(1e7+5)
#define MAX2D (int)(1e3+5)
#define itn int
#define inf 5e18
#define MOD (int)(1e9 + 7)
#define pb push_back
#define mk make_pair
#define all(x) x.begin(), x.end()
#define rall(x) x.rbegin(),x.rend()
#define sitr set<int>::iterator
#define mitr map<int, int>::iterator
#define pii pair<int, int>
#define vii vector<pii>
#define vi vector<int>
#define vll vector<unsigned int>
#define test  \
    int t;    \
    cin >> t; \
    while (t--)
#define fast                       \
    ios_base ::sync_with_stdio(0); \
    cin.tie(NULL);                 \
    cout.tie(NULL)
using namespace std;

void __print(int x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define see(x...)                 \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define see(x...)
#endif
/*
int a[(int)MAX];
vi v;
void sieve(int max = (int)1e7) {
    for(int i=0;i<=max;i++) a[i] = 1;
    a[0] = a[1] = 0;
    for(int i=2;i<=(int)sqrt(max);i++) {
        if(a[i] == 1) {
            for(int j=i*i;j<=max;j+=i) a[j] = 0;
            v.pb(i);
        }
    }
    for(int i=(int)sqrt(max)+1;i<=max;i++) {
        if(a[i] == 1) v.pb(i);
    }
}

int SPF[(int)MAX];
void spf(int max = (int)1e7) {
    for(int i=0;i<=max;i++) SPF[i] = 1;
    SPF[0] = SPF[1] = 0;
    for(int i=2;i<=sqrt(max);i++) {
        if(SPF[i] == 1) {
            for(int j = i;j<=max;j+=i) if(SPF[j] == 1) SPF[j] = i;
        }
    }
    for(int i=sqrt(max)+1;i<=max;i++) if(SPF[i] == 1) SPF[i] = i;
}
*/

//calculate factorial...
//vi f(MAX); void fact(int max = (int)1e7){f[0] = 1, f[1] = 1;for (int i = 2; i <= max; i++)f[i] = (i * f[i - 1]) % MOD;}

//int nCrMODm(int n, int r, int m = MOD){fact();if(r == 0) return 1; int x = f[n], y = f[n - r], z = f[r]; return (x * mod__inverse(y) % m * mod__inverse(z) % m + m) % m;}
//int I_fpow(int x,int y,int p = MOD){int res = 1;x = x % p;while (y > 0){if (y & 1) res = (res * x) % p;y = y >> 1;x = (x * x) % p;} return res;}

//int palindrome (string s){int x; if(!(s.length()%2)) x = s.length()/2 - 1; else x = s.length()/2; for(int i=0;i<=x;i++) {if(s[i] != s[s.length()-1-i]) return 0; } return 1; }
//int palindrome (int n){int x;string s = tostring(n); if(!(s.length()%2)) x = s.length()/2 - 1; else x = s.length()/2; for(int i=0;i<=x;i++) {if(s[i] != s[s.length()-1-i]) return 0; } return 1; }
//int toint(const string &s) {stringstream ss; ss << s; int x; ss >> x; return x;}
//string tostring ( int number ){stringstream ss; ss<< number; return ss.str();}
// Addition of 2 strings ... based on the addition performed with the help of carry.
//string add2strings(string s1,string s2){if(s1.length()>s2.length())swap(s1,s2);int n = s1.length();int m = s2.length();int carry = 0;reverse(all(s1));reverse(all(s2));string ans = "";for(int i=0;i<n;i++){int sum = (char)(s1[i]-'0')+(char)(s2[i]-'0')+carry;ans += (char)(sum%10 + '0');carry = sum/10;}for(int i=n;i<m;i++){int sum = (char)(s2[i]-'0')+carry;ans += (char)(sum%10 + '0');carry = sum/10;}if(carry)ans += (char)(carry+'0');reverse(all(ans));return ans;}

//key to euclids extended --> gcd(a,b) = gcd(b,a%b)
//also a%b = a-(a/b)*b;
//hence ax+by = bx1+(a%b)y1.. ax+by = bx1+(ay1-(a/b)*by1)..
//comparing x = y1;
//y = x1-(a/b)*y1
//void extendedEuclid(int a,int b,int &x,int &y){int res;if(b == 0){res = a;x = 1;y = 0;}else{extendedEuclid(b,a%b,x,y);int t = x;x = y;y = t - (a/b)*x;}}

//if m is prime fermats little theorem can be used
//int modInverse(int a,int m){return I_fpow(a,m-2);}

//if not
//In extendedGCD x is the mod mult inverse of a under b and y is the mod mult inverse of b under a
//Inverse exist if a,m is co-prime
//int mod__Inverse(int a,int m){int x,y;extendedEuclid(a,m,x,y); return (x%m+m)%m;}
//int rr[] = {-1,0,1,0};
//int cc[] = {0,1,0,-1};

double eps = 0.00000001;
vector<double> x(MAX), v(MAX);
int n;
bool good(double g) {
    vector<pair<double,double>> pos;
    for(int i=0;i<n;i++) {
        double l_lim = x[i]-v[i]*g;
        double r_lim = x[i]+v[i]*g;
        pos.pb({l_lim,r_lim});
    }
    double lx = 0, rx = inf;
    for(int i=0;i<n;i++) {
        lx = max(lx,pos[i].first), rx = min(rx,pos[i].second);
    }
    if(rx-lx > 0) return true;
    return false;
}

double f() {
    double l = 0.0f, r = 1e9f;
    double ans = l;
    for(int i=0;i<100 && l+eps < r;i++) {
        double mid = 0.5f*(l+r);
        if(good(mid)) {
            ans = mid, r = mid;
        }
        else l = mid;
    }
    return ans;
}

signed main()
{
    fast;
    cin>>n;
    for(int i=0;i<n;i++) cin>>x[i];
    for(int i=0;i<n;i++) cin>>v[i];
    cout<<f();
    return 0;
}

/*
max factors number = 720720 --> 240 factors
max factors number = 1441440 -->288 factors

Beautiful program
Please run for me.
I've tried you in BASIC,
FORTRAN and C.
Beautiful program,
You've errors galore.
And each time I run you,
You're swapped out of core.
*/


/*                                 ___ _____
  ___  _ __ ___   ___  __ _  __ _ / _ \___  |
 / _ \| '_ ` _ \ / _ \/ _` |/ _` | | | | / /
| (_) | | | | | |  __/ (_| | (_| | |_| |/ /
 \___/|_| |_| |_|\___|\__, |\__,_|\___//_/
                      |___/
*/
// Getting better at it ! ! !
#include <bits/stdc++.h>
#include <string.h>
#define int long long
#define MAX (int)(1e7+5)
#define MAX2D (int)(1e3+5)
#define itn int
#define inf 5e18
#define MOD (int)(1e9 + 7)
#define pb push_back
#define mk make_pair
#define all(x) x.begin(), x.end()
#define rall(x) x.rbegin(),x.rend()
#define sitr set<int>::iterator
#define mitr map<int, int>::iterator
#define pii pair<int, int>
#define vii vector<pii>
#define vi vector<int>
#define vll vector<unsigned int>
#define test  \
    int t;    \
    cin >> t; \
    while (t--)
#define fast                       \
    ios_base ::sync_with_stdio(0); \
    cin.tie(NULL);                 \
    cout.tie(NULL)
using namespace std;

void __print(int x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define see(x...)                 \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define see(x...)
#endif
/*
int a[(int)MAX];
vi v;
void sieve(int max = (int)1e7) {
    for(int i=0;i<=max;i++) a[i] = 1;
    a[0] = a[1] = 0;
    for(int i=2;i<=(int)sqrt(max);i++) {
        if(a[i] == 1) {
            for(int j=i*i;j<=max;j+=i) a[j] = 0;
            v.pb(i);
        }
    }
    for(int i=(int)sqrt(max)+1;i<=max;i++) {
        if(a[i] == 1) v.pb(i);
    }
}

int SPF[(int)MAX];
void spf(int max = (int)1e7) {
    for(int i=0;i<=max;i++) SPF[i] = 1;
    SPF[0] = SPF[1] = 0;
    for(int i=2;i<=sqrt(max);i++) {
        if(SPF[i] == 1) {
            for(int j = i;j<=max;j+=i) if(SPF[j] == 1) SPF[j] = i;
        }
    }
    for(int i=sqrt(max)+1;i<=max;i++) if(SPF[i] == 1) SPF[i] = i;
}
*/

//calculate factorial...
//vi f(MAX); void fact(int max = (int)1e7){f[0] = 1, f[1] = 1;for (int i = 2; i <= max; i++)f[i] = (i * f[i - 1]) % MOD;}

//int nCrMODm(int n, int r, int m = MOD){fact();if(r == 0) return 1; int x = f[n], y = f[n - r], z = f[r]; return (x * mod__inverse(y) % m * mod__inverse(z) % m + m) % m;}
//int I_fpow(int x,int y,int p = MOD){int res = 1;x = x % p;while (y > 0){if (y & 1) res = (res * x) % p;y = y >> 1;x = (x * x) % p;} return res;}

//int palindrome (string s){int x; if(!(s.length()%2)) x = s.length()/2 - 1; else x = s.length()/2; for(int i=0;i<=x;i++) {if(s[i] != s[s.length()-1-i]) return 0; } return 1; }
//int palindrome (int n){int x;string s = tostring(n); if(!(s.length()%2)) x = s.length()/2 - 1; else x = s.length()/2; for(int i=0;i<=x;i++) {if(s[i] != s[s.length()-1-i]) return 0; } return 1; }
//int toint(const string &s) {stringstream ss; ss << s; int x; ss >> x; return x;}
//string tostring ( int number ){stringstream ss; ss<< number; return ss.str();}
// Addition of 2 strings ... based on the addition performed with the help of carry.
//string add2strings(string s1,string s2){if(s1.length()>s2.length())swap(s1,s2);int n = s1.length();int m = s2.length();int carry = 0;reverse(all(s1));reverse(all(s2));string ans = "";for(int i=0;i<n;i++){int sum = (char)(s1[i]-'0')+(char)(s2[i]-'0')+carry;ans += (char)(sum%10 + '0');carry = sum/10;}for(int i=n;i<m;i++){int sum = (char)(s2[i]-'0')+carry;ans += (char)(sum%10 + '0');carry = sum/10;}if(carry)ans += (char)(carry+'0');reverse(all(ans));return ans;}

//key to euclids extended --> gcd(a,b) = gcd(b,a%b)
//also a%b = a-(a/b)*b;
//hence ax+by = bx1+(a%b)y1.. ax+by = bx1+(ay1-(a/b)*by1)..
//comparing x = y1;
//y = x1-(a/b)*y1
//void extendedEuclid(int a,int b,int &x,int &y){int res;if(b == 0){res = a;x = 1;y = 0;}else{extendedEuclid(b,a%b,x,y);int t = x;x = y;y = t - (a/b)*x;}}

//if m is prime fermats little theorem can be used
//int modInverse(int a,int m){return I_fpow(a,m-2);}

//if not
//In extendedGCD x is the mod mult inverse of a under b and y is the mod mult inverse of b under a
//Inverse exist if a,m is co-prime
//int mod__Inverse(int a,int m){int x,y;extendedEuclid(a,m,x,y); return (x%m+m)%m;}
//int rr[] = {-1,0,1,0};
//int cc[] = {0,1,0,-1};

double eps = 0.0000001;
vector<double> x(MAX), v(MAX);
int n;
bool good(double g) {
    vector<pair<double,double>> pos;
    for(int i=0;i<n;i++) {
        double l_lim = x[i]-v[i]*g;
        double r_lim = x[i]+v[i]*g;
        pos.pb({l_lim,r_lim});
    }
    double lx = 0, rx = inf;
    for(int i=0;i<n;i++) {
        lx = max(lx,pos[i].first), rx = min(rx,pos[i].second);
    }
    if(rx-lx > 0) return true;
    return false;
}

double f() {
    double l = 0.0, r = 1e9;
    double ans = l;
    for(int i=0;i<200 && l+eps <= r;i++) {
        double mid = (double)(l+r)/2;
        if(good(mid)) {
            ans = mid, r = mid;
        }
        else l = mid;
    }
    return ans;
}

signed main()
{
    fast;
    cout<<fixed<<setprecision(10);
    cin>>n;
    for(int i=0;i<n;i++) cin>>x[i];
    for(int i=0;i<n;i++) cin>>v[i];
    cout<<f();
    return 0;
}

/*
max factors number = 720720 --> 240 factors
max factors number = 1441440 -->288 factors

Beautiful program
Please run for me.
I've tried you in BASIC,
FORTRAN and C.
Beautiful program,
You've errors galore.
And each time I run you,
You're swapped out of core.
*/


/*                                 ___ _____
  ___  _ __ ___   ___  __ _  __ _ / _ \___  |
 / _ \| '_ ` _ \ / _ \/ _` |/ _` | | | | / /
| (_) | | | | | |  __/ (_| | (_| | |_| |/ /
 \___/|_| |_| |_|\___|\__, |\__,_|\___//_/
                      |___/
*/
// Getting better at it ! ! !
#include <bits/stdc++.h>
#include <string.h>
#define int long long
#define MAX (int)(1e7+5)
#define MAX2D (int)(1e3+5)
#define itn int
#define inf 5e18
#define MOD (int)(1e9 + 7)
#define pb push_back
#define mk make_pair
#define all(x) x.begin(), x.end()
#define rall(x) x.rbegin(),x.rend()
#define sitr set<int>::iterator
#define mitr map<int, int>::iterator
#define pii pair<int, int>
#define vii vector<pii>
#define vi vector<int>
#define vll vector<unsigned int>
#define test  \
    int t;    \
    cin >> t; \
    while (t--)
#define fast                       \
    ios_base ::sync_with_stdio(0); \
    cin.tie(NULL);                 \
    cout.tie(NULL)
using namespace std;

void __print(int x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define see(x...)                 \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define see(x...)
#endif
/*
int a[(int)MAX];
vi v;
void sieve(int max = (int)1e7) {
    for(int i=0;i<=max;i++) a[i] = 1;
    a[0] = a[1] = 0;
    for(int i=2;i<=(int)sqrt(max);i++) {
        if(a[i] == 1) {
            for(int j=i*i;j<=max;j+=i) a[j] = 0;
            v.pb(i);
        }
    }
    for(int i=(int)sqrt(max)+1;i<=max;i++) {
        if(a[i] == 1) v.pb(i);
    }
}

int SPF[(int)MAX];
void spf(int max = (int)1e7) {
    for(int i=0;i<=max;i++) SPF[i] = 1;
    SPF[0] = SPF[1] = 0;
    for(int i=2;i<=sqrt(max);i++) {
        if(SPF[i] == 1) {
            for(int j = i;j<=max;j+=i) if(SPF[j] == 1) SPF[j] = i;
        }
    }
    for(int i=sqrt(max)+1;i<=max;i++) if(SPF[i] == 1) SPF[i] = i;
}
*/

//calculate factorial...
//vi f(MAX); void fact(int max = (int)1e7){f[0] = 1, f[1] = 1;for (int i = 2; i <= max; i++)f[i] = (i * f[i - 1]) % MOD;}

//int nCrMODm(int n, int r, int m = MOD){fact();if(r == 0) return 1; int x = f[n], y = f[n - r], z = f[r]; return (x * mod__inverse(y) % m * mod__inverse(z) % m + m) % m;}
//int I_fpow(int x,int y,int p = MOD){int res = 1;x = x % p;while (y > 0){if (y & 1) res = (res * x) % p;y = y >> 1;x = (x * x) % p;} return res;}

//int palindrome (string s){int x; if(!(s.length()%2)) x = s.length()/2 - 1; else x = s.length()/2; for(int i=0;i<=x;i++) {if(s[i] != s[s.length()-1-i]) return 0; } return 1; }
//int palindrome (int n){int x;string s = tostring(n); if(!(s.length()%2)) x = s.length()/2 - 1; else x = s.length()/2; for(int i=0;i<=x;i++) {if(s[i] != s[s.length()-1-i]) return 0; } return 1; }
//int toint(const string &s) {stringstream ss; ss << s; int x; ss >> x; return x;}
//string tostring ( int number ){stringstream ss; ss<< number; return ss.str();}
// Addition of 2 strings ... based on the addition performed with the help of carry.
//string add2strings(string s1,string s2){if(s1.length()>s2.length())swap(s1,s2);int n = s1.length();int m = s2.length();int carry = 0;reverse(all(s1));reverse(all(s2));string ans = "";for(int i=0;i<n;i++){int sum = (char)(s1[i]-'0')+(char)(s2[i]-'0')+carry;ans += (char)(sum%10 + '0');carry = sum/10;}for(int i=n;i<m;i++){int sum = (char)(s2[i]-'0')+carry;ans += (char)(sum%10 + '0');carry = sum/10;}if(carry)ans += (char)(carry+'0');reverse(all(ans));return ans;}

//key to euclids extended --> gcd(a,b) = gcd(b,a%b)
//also a%b = a-(a/b)*b;
//hence ax+by = bx1+(a%b)y1.. ax+by = bx1+(ay1-(a/b)*by1)..
//comparing x = y1;
//y = x1-(a/b)*y1
//void extendedEuclid(int a,int b,int &x,int &y){int res;if(b == 0){res = a;x = 1;y = 0;}else{extendedEuclid(b,a%b,x,y);int t = x;x = y;y = t - (a/b)*x;}}

//if m is prime fermats little theorem can be used
//int modInverse(int a,int m){return I_fpow(a,m-2);}

//if not
//In extendedGCD x is the mod mult inverse of a under b and y is the mod mult inverse of b under a
//Inverse exist if a,m is co-prime
//int mod__Inverse(int a,int m){int x,y;extendedEuclid(a,m,x,y); return (x%m+m)%m;}
//int rr[] = {-1,0,1,0};
//int cc[] = {0,1,0,-1};

double eps = 0.0000001;
vector<double> x(MAX), v(MAX);
int n;
bool good(double g) {
    vector<pair<double,double>> pos;
    for(int i=0;i<n;i++) {
        double l_lim = x[i]-v[i]*g;
        double r_lim = x[i]+v[i]*g;
        pos.pb({l_lim,r_lim});
    }
    double lx = 0, rx = inf;
    for(int i=0;i<n;i++) {
        lx = max(lx,pos[i].first), rx = min(rx,pos[i].second);
    }
    if(rx-lx > 0) return true;
    return false;
}

double f() {
    double l = 0.0, r = 1e9;
    double ans = l;
    for(int i=0;i<200 && l+eps <= r;i++) {
        double mid = sqrt(l*r);
        if(good(mid)) {
            ans = mid, r = mid;
        }
        else l = mid;
    }
    return ans;
}

signed main()
{
    fast;
    cout<<fixed<<setprecision(10);
    cin>>n;
    for(int i=0;i<n;i++) cin>>x[i];
    for(int i=0;i<n;i++) cin>>v[i];
    cout<<f();
    return 0;
}

/*
max factors number = 720720 --> 240 factors
max factors number = 1441440 -->288 factors

Beautiful program
Please run for me.
I've tried you in BASIC,
FORTRAN and C.
Beautiful program,
You've errors galore.
And each time I run you,
You're swapped out of core.
*/


/*                                 ___ _____
  ___  _ __ ___   ___  __ _  __ _ / _ \___  |
 / _ \| '_ ` _ \ / _ \/ _` |/ _` | | | | / /
| (_) | | | | | |  __/ (_| | (_| | |_| |/ /
 \___/|_| |_| |_|\___|\__, |\__,_|\___//_/
                      |___/
*/
// Getting better at it ! ! !
#include <bits/stdc++.h>
#include <string.h>
#define int long long
#define MAX (int)(1e7+5)
#define MAX2D (int)(1e3+5)
#define itn int
#define inf 5e18
#define MOD (int)(1e9 + 7)
#define pb push_back
#define mk make_pair
#define all(x) x.begin(), x.end()
#define rall(x) x.rbegin(),x.rend()
#define sitr set<int>::iterator
#define mitr map<int, int>::iterator
#define pii pair<int, int>
#define vii vector<pii>
#define vi vector<int>
#define vll vector<unsigned int>
#define test  \
    int t;    \
    cin >> t; \
    while (t--)
#define fast                       \
    ios_base ::sync_with_stdio(0); \
    cin.tie(NULL);                 \
    cout.tie(NULL)
using namespace std;

void __print(int x) { cerr << x; }
void __print(float x) { cerr << x; }
void __print(double x) { cerr << x; }
void __print(long double x) { cerr << x; }
void __print(char x) { cerr << '\'' << x << '\''; }
void __print(const char *x) { cerr << '\"' << x << '\"'; }
void __print(const string &x) { cerr << '\"' << x << '\"'; }
void __print(bool x) { cerr << (x ? "true" : "false"); }

template <typename T, typename V>
void __print(const pair<T, V> &x)
{
    cerr << '{';
    __print(x.first);
    cerr << ',';
    __print(x.second);
    cerr << '}';
}
template <typename T>
void __print(const T &x)
{
    int f = 0;
    cerr << '{';
    for (auto &i : x)
        cerr << (f++ ? "," : ""), __print(i);
    cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v)
{
    __print(t);
    if (sizeof...(v))
        cerr << ", ";
    _print(v...);
}
#ifndef ONLINE_JUDGE
#define see(x...)                 \
    cerr << "[" << #x << "] = ["; \
    _print(x)
#else
#define see(x...)
#endif
/*
int a[(int)MAX];
vi v;
void sieve(int max = (int)1e7) {
    for(int i=0;i<=max;i++) a[i] = 1;
    a[0] = a[1] = 0;
    for(int i=2;i<=(int)sqrt(max);i++) {
        if(a[i] == 1) {
            for(int j=i*i;j<=max;j+=i) a[j] = 0;
            v.pb(i);
        }
    }
    for(int i=(int)sqrt(max)+1;i<=max;i++) {
        if(a[i] == 1) v.pb(i);
    }
}

int SPF[(int)MAX];
void spf(int max = (int)1e7) {
    for(int i=0;i<=max;i++) SPF[i] = 1;
    SPF[0] = SPF[1] = 0;
    for(int i=2;i<=sqrt(max);i++) {
        if(SPF[i] == 1) {
            for(int j = i;j<=max;j+=i) if(SPF[j] == 1) SPF[j] = i;
        }
    }
    for(int i=sqrt(max)+1;i<=max;i++) if(SPF[i] == 1) SPF[i] = i;
}
*/

//calculate factorial...
//vi f(MAX); void fact(int max = (int)1e7){f[0] = 1, f[1] = 1;for (int i = 2; i <= max; i++)f[i] = (i * f[i - 1]) % MOD;}

//int nCrMODm(int n, int r, int m = MOD){fact();if(r == 0) return 1; int x = f[n], y = f[n - r], z = f[r]; return (x * mod__inverse(y) % m * mod__inverse(z) % m + m) % m;}
//int I_fpow(int x,int y,int p = MOD){int res = 1;x = x % p;while (y > 0){if (y & 1) res = (res * x) % p;y = y >> 1;x = (x * x) % p;} return res;}

//int palindrome (string s){int x; if(!(s.length()%2)) x = s.length()/2 - 1; else x = s.length()/2; for(int i=0;i<=x;i++) {if(s[i] != s[s.length()-1-i]) return 0; } return 1; }
//int palindrome (int n){int x;string s = tostring(n); if(!(s.length()%2)) x = s.length()/2 - 1; else x = s.length()/2; for(int i=0;i<=x;i++) {if(s[i] != s[s.length()-1-i]) return 0; } return 1; }
//int toint(const string &s) {stringstream ss; ss << s; int x; ss >> x; return x;}
//string tostring ( int number ){stringstream ss; ss<< number; return ss.str();}
// Addition of 2 strings ... based on the addition performed with the help of carry.
//string add2strings(string s1,string s2){if(s1.length()>s2.length())swap(s1,s2);int n = s1.length();int m = s2.length();int carry = 0;reverse(all(s1));reverse(all(s2));string ans = "";for(int i=0;i<n;i++){int sum = (char)(s1[i]-'0')+(char)(s2[i]-'0')+carry;ans += (char)(sum%10 + '0');carry = sum/10;}for(int i=n;i<m;i++){int sum = (char)(s2[i]-'0')+carry;ans += (char)(sum%10 + '0');carry = sum/10;}if(carry)ans += (char)(carry+'0');reverse(all(ans));return ans;}

//key to euclids extended --> gcd(a,b) = gcd(b,a%b)
//also a%b = a-(a/b)*b;
//hence ax+by = bx1+(a%b)y1.. ax+by = bx1+(ay1-(a/b)*by1)..
//comparing x = y1;
//y = x1-(a/b)*y1
//void extendedEuclid(int a,int b,int &x,int &y){int res;if(b == 0){res = a;x = 1;y = 0;}else{extendedEuclid(b,a%b,x,y);int t = x;x = y;y = t - (a/b)*x;}}

//if m is prime fermats little theorem can be used
//int modInverse(int a,int m){return I_fpow(a,m-2);}

//if not
//In extendedGCD x is the mod mult inverse of a under b and y is the mod mult inverse of b under a
//Inverse exist if a,m is co-prime
//int mod__Inverse(int a,int m){int x,y;extendedEuclid(a,m,x,y); return (x%m+m)%m;}
//int rr[] = {-1,0,1,0};
//int cc[] = {0,1,0,-1};

double eps = 0.0000001;
vector<double> x(MAX), v(MAX);
int n;
bool good(double g) {
    vector<pair<double,double>> pos;
    for(int i=0;i<n;i++) {
        double l_lim = x[i]-v[i]*g;
        double r_lim = x[i]+v[i]*g;
        pos.pb({l_lim,r_lim});
    }
    double lx = 0, rx = inf;
    for(int i=0;i<n;i++) {
        lx = max(lx,pos[i].first), rx = min(rx,pos[i].second);
    }
    if(rx-lx > 0) return true;
    return false;
}

double f() {
    double l = 0.0, r = 1e9;
    double ans = l;
    for(int i=0;i<200 && l+eps <= r;i++) {
        double mid = (l > 1 && r > 1 ? sqrt(l*r) : (l+r)/2);
        if(good(mid)) {
            ans = mid, r = mid;
        }
        else l = mid;
    }
    return ans;
}

signed main()
{
    fast;
    cout<<fixed<<setprecision(10);
    cin>>n;
    for(int i=0;i<n;i++) cin>>x[i];
    for(int i=0;i<n;i++) cin>>v[i];
    cout<<f();
    return 0;
}

/*
max factors number = 720720 --> 240 factors
max factors number = 1441440 -->288 factors

Beautiful program
Please run for me.
I've tried you in BASIC,
FORTRAN and C.
Beautiful program,
You've errors galore.
And each time I run you,
You're swapped out of core.
*/


#include <iostream>
#include <algorithm>
#include <vector>
#include <string.h>
#include <cmath>
#include <math.h>
#include <ctime>
#include <cstring>
#include <climits>
#include <sstream>
#include <array>
#include <tuple>
#include <set>
#include <iterator>
#include <cstdio>
#include <string>
#include <stack>
#include <valarray>
#include <utility>
#include <iomanip>
#include <list>
#include <numeric>
#include <regex>
#include <map>
#include <queue>
#include <deque>
#include <unordered_set>
#include <unordered_map>

using namespace std;

#define ll          long long
#define PI          3.1415926535
#define pb          push_back
#define ins         insert
#define INF         LLONG_MAX
#define mk          make_pair
#define lb(v,x)     lower_bound(all(v),x)
#define ub(v,x)     upper_bound(all(v),x)
#define ff          first
#define ss          second
#define rev         reverse
#define umap        unordered_map
#define endl        "\n"
#define max3(x,y,z)  max(x,max(y,z))
#define min3(x,y,z)  min(x,min(y,z))
#define sz(a)       (ll)a.size()
#define double      long double
#define minpq       priority_queue <ll,vector<ll>,greater<ll> >
#define fill(x,y)   memset(x,y,sizeof(x))
#define all(x)      (x).begin(), (x).end()
#define rall(x)     (x).rbegin(), (x).rend()
#define MOD         1000000007 //1e9+7
#define bp(n)       __builtin_popcountll(n)
#define mxt(a)      *(max_element(a.begin(),a.end()))
#define mnt(a)      *(min_element(a.begin(),a.end())
#define unique_sort(c) (sort(all(c)), c.resize(distance(c.begin(),unique(c.begin(),c.end()))))
#define rep(i, a, b) for(ll i = (a); i<= (b); ++i)
#define trav(a, x) 	 for(auto &a : x)
#define re(i,n)      for(ll i = 0; i < n; ++i)
const ll N = 2e5 + 7;
typedef pair<ll,ll>   pii;
typedef vector<pii>   vpii;
typedef vector<ll>    vll;
const string alpha = "abcdefghijklmnopqrstuvwxyz";
ll power(ll x,ll y){ll res=1;x=x;while(y>0){if(y&1)res=(res*x);y=y>>1;x=(x*x);}return res;}
template<typename T> T gcd(T a,T b){ if(a==0) return b; return gcd(b%a,a); }
template<typename T> T powm(T a,T b, ll m){T cnt=1; while(b>0){ if(b%2==1) cnt=(cnt*a)%m; b/=2; a=(a*a)%m; }return cnt%m;}
ll ncr(ll n,ll r){ll res=1;if(r>n)return 0;if(r>n-r)r=n-r;for(ll i=0;i<r;i++){res*=(n-i);res/=(i+1);}return res;}
ll sqr(ll x) { return x * x;}
// always use 1ll*ans to avoid signed integer overflow;
void prec(){

}
ll x[60005],v[60005],n;
bool check(double time){
	double l=1,r=1e9;
	re(i,n){
		double cl=x[i]-time*v[i],cr=x[i]+time*v[i];
		if(cl>r||cr<l)
				return false;
			if(cl>l&&cr<r) {
				l=cl;
				r=cr;
			} else if(cl>l&&cr>r)
				l=cl;
			else if(cl<l&&cr<r)
				r=cr;
	}
	return true;
}
void solve(){
	cin>>n;
	re(i,n) cin>>x[i];re(i,n) cin>>v[i];
	double l=0,r=1e9;
	while(r-l>1e-7){
		double mid=(l+r)/2;
		if(check(mid)) r=mid;
		else l=mid;
	}
	cout<<l<<endl;
}
int main()
{
    cin.sync_with_stdio(0); cin.tie(0);
	cin.exceptions(cin.failbit);
    int tc=1;
    //cin>>tc;
    prec();
    while(tc--)
    	solve();
    return 0;
}


#include <iostream>
#include <algorithm>
#include <vector>
#include <string.h>
#include <cmath>
#include <math.h>
#include <ctime>
#include <cstring>
#include <climits>
#include <sstream>
#include <array>
#include <tuple>
#include <set>
#include <iterator>
#include <cstdio>
#include <string>
#include <stack>
#include <valarray>
#include <utility>
#include <iomanip>
#include <list>
#include <numeric>
#include <regex>
#include <map>
#include <queue>
#include <deque>
#include <unordered_set>
#include <unordered_map>

using namespace std;

#define ll          long long
#define PI          3.1415926535
#define pb          push_back
#define ins         insert
#define INF         LLONG_MAX
#define mk          make_pair
#define lb(v,x)     lower_bound(all(v),x)
#define ub(v,x)     upper_bound(all(v),x)
#define ff          first
#define ss          second
#define rev         reverse
#define umap        unordered_map
#define endl        "\n"
#define max3(x,y,z)  max(x,max(y,z))
#define min3(x,y,z)  min(x,min(y,z))
#define sz(a)       (ll)a.size()
#define double      long double
#define minpq       priority_queue <ll,vector<ll>,greater<ll> >
#define fill(x,y)   memset(x,y,sizeof(x))
#define all(x)      (x).begin(), (x).end()
#define rall(x)     (x).rbegin(), (x).rend()
#define MOD         1000000007 //1e9+7
#define bp(n)       __builtin_popcountll(n)
#define mxt(a)      *(max_element(a.begin(),a.end()))
#define mnt(a)      *(min_element(a.begin(),a.end())
#define unique_sort(c) (sort(all(c)), c.resize(distance(c.begin(),unique(c.begin(),c.end()))))
#define rep(i, a, b) for(ll i = (a); i<= (b); ++i)
#define trav(a, x) 	 for(auto &a : x)
#define re(i,n)      for(ll i = 0; i < n; ++i)
const ll N = 2e5 + 7;
typedef pair<ll,ll>   pii;
typedef vector<pii>   vpii;
typedef vector<ll>    vll;
const string alpha = "abcdefghijklmnopqrstuvwxyz";
ll power(ll x,ll y){ll res=1;x=x;while(y>0){if(y&1)res=(res*x);y=y>>1;x=(x*x);}return res;}
template<typename T> T gcd(T a,T b){ if(a==0) return b; return gcd(b%a,a); }
template<typename T> T powm(T a,T b, ll m){T cnt=1; while(b>0){ if(b%2==1) cnt=(cnt*a)%m; b/=2; a=(a*a)%m; }return cnt%m;}
ll ncr(ll n,ll r){ll res=1;if(r>n)return 0;if(r>n-r)r=n-r;for(ll i=0;i<r;i++){res*=(n-i);res/=(i+1);}return res;}
ll sqr(ll x) { return x * x;}
// always use 1ll*ans to avoid signed integer overflow;
void prec(){

}
ll x[60005],v[60005],n;
bool check(double time){
	double l=1,r=1e9;
	re(i,n){
		double cl=x[i]-time*v[i],cr=x[i]+time*v[i];
		if(cl>r||cr<l)
				return false;
			if(cl>l&&cr<r) {
				l=cl;
				r=cr;
			} else if(cl>l&&cr>r)
				l=cl;
			else if(cl<l&&cr<r)
				r=cr;
	}
	return true;
}
void solve(){
	cin>>n;
	re(i,n) cin>>x[i];re(i,n) cin>>v[i];
	double l=0,r=1e9;
	while(r-l>1e-7){
		double mid=(l+r)/2;
		if(check(mid)) r=mid;
		else l=mid;
	}
	cout<<fixed<<setprecision(12)<<l<<endl;
}
int main()
{
    cin.sync_with_stdio(0); cin.tie(0);
	cin.exceptions(cin.failbit);
    int tc=1;
    //cin>>tc;
    prec();
    while(tc--)
    	solve();
    return 0;
}


#include <iostream>
#include <stdio.h>
#include <string.h>
#include <map>
using namespace std;

const int maxn=100005;

int a[maxn],b[maxn];

int main()
{
    int n,m,c;
    while (cin>>n>>m>>c)
    {
       for (int i=1;i<=n;i++) scanf("%d",&a[i]);
       for (int i=1;i<=m;i++) scanf("%d",&b[i]);
       int t=0;
       for (int i=1;i<=n;i++)
       {
           if (i <= m) t+=b[i];
           if (i > n-m+1) t-=b[i-(n-m+1)];
           printf("%d ",(a[i] + t + c)%c);
       }
       puts("");
    }
    return 0;
}


#include<iostream>
#include<list>
#include<vector>
#include<algorithm>
#include<set>
#include<map>
#define MAX_N 100000
using namespace std;

int N, M, c;

int ori[MAX_N];
int cri[MAX_N];
long long somma[MAX_N+1];

int main(void)
{
	cin >> N >> M >> c;
	for(int i=0;i<N;i++)
		cin >> ori[i];
	for(int i=0;i<M;i++)
		cin >> cri[i];
	for(int i=0;i<M;i++)
		somma[i+1]=(long long)somma[i]+cri[i];
	for(int i=0;i<N;i++)
	{
		int passanti=M;
		passanti=min(passanti, i+1);
		passanti=min(passanti, N-i);

		int lastpassante=M-1;
		lastpassante=min(lastpassante, i);
		cout << i << " " << lastpassante << " " << passanti << endl;
		ori[i]+=(somma[lastpassante+1]-somma[lastpassante-passanti+1])%c;
		ori[i]%=c;
	}
	for(int i=0;i<N;i++)
		cout << ori[i] << " ";
	return 0;
}


#include<iostream>
#include<list>
#include<vector>
#include<algorithm>
#include<set>
#include<map>
#define MAX_N 100000
using namespace std;

int N, M, c;

int ori[MAX_N];
int cri[MAX_N];
long long somma[MAX_N];

int main(void)
{
	cin >> N >> M >> c;
	for(int i=0;i<N;i++)
		cin >> ori[i];
	for(int i=0;i<M;i++)
		cin >> cri[i];
	for(int i=0;i<M;i++)
		somma[i+1]=(long long)somma[i]+cri[i];
	for(int i=0;i<N;i++)
	{
		int passanti=M;
		passanti=min(passanti, i+1);
		passanti=min(passanti, N-i);

		int lastpassante=M-1;
		lastpassante=min(lastpassante, i);
		cout << i << " " << lastpassante << " " << passanti << endl;
		ori[i]+=(somma[lastpassante+1]-somma[lastpassante-passanti+1])%c;
		ori[i]%=c;
	}
	for(int i=0;i<N;i++)
		cout << ori[i] << " ";
	return 0;
}