1 #include<stdio.h> 2 int main() 3 { 4 int n,k; 5 while(~scanf("%d%d",&n,&k)) 6 printf("%d ",n<k?2:(n*2/k+(n*2%k?1:0))); 7 }