#include <bits/stdc++.h>
using namespace std;
long long tests;
long long n, k, x, a[1000256], cnt;
void solve() {
  cin >> n >> k >> x;
  for (int i = 1; i <= n; i++) cin >> a[i];
  sort(a + 1, a + n + 1);
  for (int i = n; k > 0; i--, k--) {
    a[i] = min(x, a[i]);
  }
  for (int i = 1; i <= n; i++) cnt += a[i];
  cout << cnt;
}
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  solve();
}
