#include <bits/stdc++.h>
using namespace std;
#define ll long long
ll ff(ll a,ll b) {
    ll t=a/b;
    if(a%b!=0)
        t++;
    return t;
}
int main()
{
    int t; cin>>t;
    while(t--){
        ll n, x;
        cin>>n>>x;
        ll sum1=0, sum2=0;
        for(int i=0;i<n;i++) {
            ll a; cin>>a;
            sum2+=ff(a,x);
           // cout<<ff(a,x)<<endl;
            sum1+=a;
        }
        cout<<ff(sum1,x)<<' '<<sum2<<endl;
    }
    
}