#include #include #include using namespace std; int main() { int L, K; cin >> L >> K; cout << K * (int)(L/(K*2 + 1)) << endl; return 0; }