#include <bits/stdc++.h>
using namespace std;
void solve() {
  long long int n, m, k;
  cin >> n >> m >> k;
  vector<long long int> a(n);
  for (long long int i = 0; i < n; i++) cin >> a[i];
  sort(a.rbegin(), a.rend());
  long long int ankit = (m / (k + 1));
  long long int jyoti = m % (k + 1);
  long long int sum = (k * a[0]) + a[1];
  cout << (sum * ankit) + (jyoti * a[0]) << endl;
}
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  solve();
  return 0;
}
