#include <bits/stdc++.h>
int n;
long long m, k, a[200005], ans, max, mex, mexi, maxi;
int main() {
  scanf("%d%lld%lld", &n, &m, &k);
  max = -10000000000;
  maxi = 0;
  mex = max;
  mexi = 0;
  for (int i = 1; i <= n; i++) {
    scanf("%lld", &a[i]);
    if (a[i] > max) {
      mex = max;
      mexi = maxi;
      max = a[i];
      maxi = i;
    } else if (a[i] > mex) {
      mex = a[i];
      mexi = i;
    }
  }
  long long x = m / (k + 1);
  ans = x * k * max + x * mex;
  ans += (m - x * (k + 1)) * max;
  printf("%lld", ans);
  return 0;
}
