#include <bits/stdc++.h>
using namespace std;
const long long INF = 1e18;
const int MAXN = 5002;
const int MOD = 998244353;
const double eps = 1e-8;
const double PI = acos(-1.0);
int main() {
  int x;
  int a, b, c;
  long long ans;
  while (scanf("%d%d%d", &a, &b, &c) != EOF) {
    ans = 0;
    for (int i = 1; i <= a; i++) {
      scanf("%d", &x);
      if (i <= a - b)
        ans += x;
      else {
        if (x > c)
          ans += c;
        else
          ans += x;
      }
    }
    printf("%I64d\n", ans);
  }
}
