L,K=map(int, input().split()) i=0 Y=0 K=2*K while L>0: L-=K Y+=K print(Y)