#include #include #include #include #include #include #include #include #include #include #include static const int MOD = 1000000007; using ll = long long; using u32 = uint32_t; using namespace std; template constexpr T INF = ::numeric_limits::max() / 32 * 15 + 208; int main() { int n, c, v; cin >> n >> c >> v; vector dp(2*n+1, INF); dp[1] = 0; for (int i = 1; i <= 2*n; ++i) { for (int j = 2*i, x = c + v; j <= 2*n; j += i, x += v) { dp[j] = min(dp[j], dp[i]+x); } } int ans = INF; for (int i = n; i <= 2*n; ++i) { ans = min(ans, dp[i]); } cout << ans << "\n"; return 0; }