#include #include #include #include #include #include #include #include #include #include using namespace std; int main(){ int d, a, b, c1, c2; float x; cin >> d >> a >> b; x = d*b/(a + b); if ((x - (int)x) > 0.5) x = x+1; else x = (int)x; cout << x * a + (d - x) * b << endl; }