#include #include #include #include using namespace std; int main(){ int L, K; cin >> L >> K; int cnt = 0; while(true){ L -= 2*K; if(L<=0) break; cnt++; } cout << cnt*K << endl; }