#include using namespace std; #define int long long #define double long double const int N = 1e6 + 10; double a[N]; int n; int k; bool cheak(double x) { int res = 0; for (int i = 1; i <= n; i++) { res += (a[i] / x); //cout << res << endl; } return res >= k; } void solve() { cout << fixed << setprecision(15); cin >> n; for (int i = 1; i <= n; i++)cin >> a[i]; cin >> k; double l = 0.0, r = 6e18 + 10; for (int i = 1; i <= 100; i++) { int mid = (l + r) / 2; if (cheak(mid)) l = mid; else r = mid; } cout << l << endl; } signed main() { ios::sync_with_stdio(0), cin.tie(0), cout.tie(0); int T = 1; //cin >> T; while (T--) { solve(); } }