#include <bits/stdc++.h>
using namespace std;
int i, j, k, n, m;
unsigned int a[41], b[41], f[41][41], h[41][41], c[41][41], d[41];
inline void prepare() {
  memset(f, 120, sizeof(f));
  memset(h, 120, sizeof(h));
  memset(c, 120, sizeof(c));
  memset(d, 120, sizeof(d));
  for (i = 0; i <= (1 << n) - 1; i++) {
    int s = 0, ma = 0;
    unsigned int cost = 0;
    for (j = 0; j <= n - 1; j++) {
      int A = i >> j & 1;
      if (!A)
        s++, ma = max(ma, s), cost += b[j];
      else
        s--, cost += a[j];
    }
    if (s >= 0)
      f[ma][s] = min(f[ma][s], cost);
    else
      h[ma][-s] = min(h[ma][-s], cost);
  }
  for (i = 0; i <= n + n; i++) {
    for (j = 0; j <= i; j++)
      for (k = 0; k <= i; k++) c[i][i - k] = min(c[i][i - k], f[j][k]);
    for (j = 0; j <= i; j++)
      for (k = 0; k <= n + n - i; k++) c[i][i + k] = min(c[i][i + k], h[j][k]);
  }
  d[0] = 0;
}
inline void mul(unsigned int a[41], unsigned int b[41][41]) {
  unsigned int c[41], i, j;
  memset(c, 120, sizeof(c));
  for (i = 0; i <= n + n; i++)
    for (j = 0; j <= n + n; j++) c[j] = min(c[j], a[i] + b[i][j]);
  for (i = 0; i <= n + n; i++) a[i] = c[i];
}
inline void mul(unsigned int a[41][41], unsigned int b[41][41]) {
  unsigned int c[41][41], i, j, k;
  memset(c, 120, sizeof(c));
  for (i = 0; i <= n + n; i++)
    for (j = 0; j <= n + n; j++)
      for (k = 0; k <= n + n; k++) c[i][k] = min(c[i][k], a[i][j] + b[j][k]);
  for (i = 0; i <= n + n; i++)
    for (j = 0; j <= n + n; j++) a[i][j] = c[i][j];
}
inline void work() {
  for (; m; m >>= 1) {
    if (m & 1) mul(d, c);
    mul(c, c);
  }
  printf("%d\n", d[0]);
}
int main() {
  scanf("%d%d", &n, &m);
  for (i = 0; i <= n - 1; i++) scanf("%d", &a[i]);
  for (i = 0; i <= n - 1; i++) scanf("%d", &b[i]);
  prepare();
  work();
  return 0;
}
