#include #define rep(i,a,b) for(int i=a;i> N; rep(i, 0, N) cin >> L[i]; sort(L, L + N, greater()); vector qu; rep(i, 0, N) rep(j, 0, 50000 / (i + 1)){ qu.push_back(1.0 * L[i] / (j + 1)); } sort(qu.begin(), qu.end(), greater()); cin >> Q; rep(q, 0, Q) { int k; cin >> k; printf("%.12f\n", qu[k - 1]); } }