func_code_string: #include <bits/stdc++.h>   using namespace std;   int vocala(char c) {     if (c ==  a  || c ==  A  || c ==  e  || c ==  E  || c ==  i  || c ==  I  ||         c ==  o  || c ==  O  || c ==  u  || c ==  U )       return 1;     if (c ==  y  || c ==  Y ) return 1;     return 0;   }   int isprime(long long n) {     if (n <= 1) return 0;     for (long long i = 2; i * i <= n; ++i)       if (n % i == 0) return 0;     return 1;   }   int isfibo(long long n) {     long long a = 5 * n * n + 4;     long long b = a - 8;     if (sqrt(a) == int(sqrt(a)) || sqrt(b) == int(sqrt(b))) return 1;     return 0;   }   int gcd(long long a, long long b) {     long long r;     while (b) {       r = a % b;       a = b;       b = r;     }     return a;   }   ifstream in( input.txt );   ofstream out( output.txt );   long long const nrmax = 1e18;   long long v[100005];   int main() {     ios_base::sync_with_stdio(0);     cin.tie(0);     cout.tie(0);     long long n;     cin >> n;     for (int i = 1; i <= n; ++i) {       cin >> v[i];     }     long long cnt = 3e9;     sort(v + 1, v + n + 1);     cnt = min(cnt, v[n] - v[2]);     cnt = min(cnt, v[n - 1] - v[1]);     cout << cnt <<   n ;     in.close();     out.close();     return 0;   }   