#include <bits/stdc++.h>   using namespace std;   const long long inf = 1e18;   const long long mod = 1e9 + 7;   signed main() {     ios_base::sync_with_stdio(false);     cin.tie(0);     long long q;     cin >> q;     ;     for (long long i = (1); i <= (q); i++) {       long long n;       cin >> n;       ;       long long r;       cin >> r;       ;       set<long long, greater<long long>> s;       for (long long i = (1); i <= (n); i++) {         long long x;         cin >> x;         ;         s.insert(x);       }       long long k = 0, st = 0;       for (long long j : s) {         if (j - r * k <= 0) {           cout << k <<   n ;           st = 1;           break;         }         k++;       }       if (!st) cout << k <<   n ;     }   }   