One day Vasya got hold of information on the Martian dollar course in bourles for the next n days. The buying prices and the selling prices for one dollar on day i are the same and are equal to ai. Vasya has b bourles. He can buy a certain number of dollars and then sell it no more than once in n days. According to Martian laws, one can buy only an integer number of dollars. Which maximal sum of money in bourles can Vasya get by the end of day n?

Input

The first line contains two integers n and b (1 ≤ n, b ≤ 2000) — the number of days and the initial number of money in bourles. The next line contains n integers ai (1 ≤ ai ≤ 2000) — the prices of Martian dollars.

Output

Print the single number — which maximal sum of money in bourles can Vasya get by the end of day n.

Examples

Input

2 4
3 7


Output

8


Input

4 10
4 3 2 1


Output

10


Input

4 10
4 2 3 1


Output

15
import java.util.*;
import java.io.*;

public class Main2 {
    public static void main(String[] args) throws Exception {
        solve();
        out.flush();
    }

    public static void solve() throws Exception {
        int n1 = ni();
        long v1 = ni();
        long[] l1 = nll(n1);
        
        long[] best = new long[n1];
        for (int i =0; i < n1; i++){
            best[i] = v1;
        }
        for (int i =0; i < n1; i++){
            for (int j = i + 1; j < n1; j++){
                long rmd = best[i] % l1[i];
                long times=  best[i] / l1[i];
                long yield = times * l1[j];
                long all = rmd + yield;
                best[j] = Math.max(best[j], all);
            }
        }
        
        long ans = Long.MIN_VALUE;
        for (long e: best){
            ans = Math.max(ans, e);
        }
        pn(ans);
    }

    public static BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
    public static StringTokenizer st = null;

    public static String nx() throws Exception {
        for (; st == null || !st.hasMoreTokens();) {
            String k1 = in.readLine();
            if (k1 == null) return null;
            st = new StringTokenizer(k1);
        }
        return st.nextToken();
    }

    public static int ni() throws Exception {
        return Integer.parseInt(nx());
    }

    public static long nl() throws Exception {
        return Long.parseLong(nx());
    }

    public static double nd() throws Exception {
        return Double.parseDouble(nx());
    }

    private static long[] nll(int n1) throws Exception {
        long[] l1 = new long[n1];
        for (int i = 0; i < n1; i++) {
            l1[i] = nl();
        }
        return l1;
    }

    public static void px(Object... l1) {
        System.out.println(Arrays.deepToString(l1));
    }

    public static boolean FLUSH = false;
    public static PrintWriter out = new PrintWriter(System.out, FLUSH);

    public static void p(Object... l1) {
        for (int i = 0; i < l1.length; i++) {
            if (i != 0) out.print(' ');
            out.print(l1[i].toString());
        }
    }

    public static void pn(Object... l1) {
        for (int i = 0; i < l1.length; i++) {
            if (i != 0) out.print(' ');
            out.print(l1[i].toString());
        }
        out.println();
    }

}
