In a public bath, there is a shower which emits water for T seconds when the switch is pushed.  If the switch is pushed when the shower is already emitting water, from that moment it will be emitting water for T seconds. Note that it does not mean that the shower emits water for T additional seconds.  N people will push the switch while passing by the shower. The i-th person will push the switch t_i seconds after the first person pushes it.  How long will the shower emit water in total?
a,b=map(int,input().split())
k=list(map(int,input().split()))

time=0
for i in range(a-1):
    tc=k[i+1]-k[i]
    if tc<b:
        time = time+tc
    else:
        time=time+b
print(time)
a,b=map(int,input().split())
k=list(map(int,input().split()))

time=b
for i in range(a-1):
    tc=k[i+1]-k[i]
    if tc<b:
        time = time+tc
    else:
        time=time+b
print(time)