【題目敘述】http://codeforces.com/contest/1380/problem/C
【解題想法】Greedy
#include <iostream>
#include <algorithm>
using namespace std;
int t, n;
long long x, a[100005];
int main(){
cin >> t;
while (t--){
cin >> n >> x;
for (int i = 0; i < n; i++){
cin >> a[i];
}
sort(a, a+n, greater<int>());
int p = 0, ans = 0;
long long mn = 1e9;
for (int i = 0; i < n; i++){
mn = min(mn, a[i]);
if (mn*(i-p+1) >= x){
ans++;
p = i+1;
mn = 1e9;
}
}
cout << ans << "\n";
}
}