<Problem>
http://ntucoder.net/Problem/Details/2201
Uses Crt;
Type arr=array[1..1000000] of longint;
Var t,i,n,k,s,j:longint; a:arr;
Procedure Sort(l,r:longint);
var i,j,tg,x:longint;
begin
i:=l; j:=r; x:=a[(l+r) div 2];
repeat
while a[i]<x do inc(i); while a[j]>x do dec(j);
if i<=j then begin tg:=a[i]; a[i]:=a[j]; a[j]:=tg; inc(i); dec(j); end;
until i>j;
if l<j then sort(l,j); if i<r then sort(i,r);
end;
Begin
readln(t);
for i:=1 to t do
begin
readln(n,k);
for j:=1 to n do read(a[j]); sort(1,n);
s:=1;
for j:=2 to n do
if a[j]-a[j-1]>k then inc(s);
writeln('Case #',i,': ',s);
end;
readln;
End.