n,T,*t=list(map(int,open(0).read().split()));print((T+sum(min(j-i,T)for i,j in zip(t,t[1:]))))
_,T,b,*t=list(map(int,open(0).read().split()))

a=T

for i in t:a+=min(i-b,T);b=i

print(a)
n, T, *t = list(map(int, open(0).read().split()))
print((T + sum(min(j - i, T) for i, j in zip(t, t[1:]))))

_, T, b, *t = list(map(int, open(0).read().split()))
a = T
for i in t:
    a += min(i - b, T)
    b = i
print(a)

-n, T, *t = list(map(int, open(0).read().split())) -print((T + sum(min(j - i, T) for i, j in zip(t, t[1:])))) +_, T, b, *t = list(map(int, open(0).read().split())) +a = T +for i in t: +    a += min(i - b, T) +    b = i +print(a)