#include #include #include #include #include #include #include #include #include #include #include using namespace std; int main() { int n; cin >> n; vector v(n); for (int i = 0; i < n; i++)cin >> v[i]; long long k; cin >> k; sort(v.begin(), v.end(), greater()); const double eps = 1e-9; double high = v[0]; double low = 0; while (high - low > eps && (high - low) / high > eps){ double mid = (high + low) / 2; long long cnt = 0; for (int i = 0; i < n; i++) { cnt += v[i] / mid; } cerr << high << " " << mid << " " << low << " " << cnt << endl; if (cnt >= k) { low = mid; } else { high = mid; } } cout << fixed << setprecision(20) << high << endl; }