#include <bits/stdc++.h>
using namespace std;
int main() {
  long long M = 101;
  long long n, l;
  cin >> n >> l;
  vector<int> v;
  for (long long i = 0; i < n; i++) {
    int j;
    cin >> j;
    v.push_back(j);
  }
  long long maxArea(0);
  for (long long u = l; u < M; u++) {
    long long area(0);
    for (long long i = 0; i < n; i++) area += u * (v[i] / u);
    maxArea = (maxArea > area) ? maxArea : area;
  }
  cout << maxArea << "\n";
  return 0;
}
