#include <bits/stdc++.h>
using namespace std;
int n, i, j, A[2][25], ar[100], k, l, m, ans, tmp;
int main() {
  memset(ar, 0, sizeof(ar));
  scanf("%d%d", &n, &m);
  for (i = 1; i <= n; i++) scanf("%d", &A[0][i % n]);
  for (i = 1; i <= n; i++) scanf("%d", &A[1][i % n]);
  ans = 0;
  ar[1] = A[0][1 % n];
  m *= n;
  for (i = 2; i <= 4 * n; i++) {
    k = min(i + 1, 4 * n);
    l = i & 1;
    for (j = l; j <= k; j += 2) {
      if (j == 0)
        ar[j] = ar[j + 1] + A[1][i % n];
      else if (j + 2 > k)
        ar[j] = ar[j - 1] + A[0][i % n];
      else
        ar[j] = min(ar[j - 1] + A[0][i % n], ar[j + 1] + A[1][i % n]);
    }
    if (i == m) {
      printf("%d\n", ar[0]);
      return 0;
    }
    if (i == n * 2) tmp = ar[0];
  }
  m -= n * 4;
  ans += (ar[0] - tmp) * (m / (n * 2));
  m %= (n * 2);
  for (i = 0; i <= m; i++) {
    k = min(i + 1, 4 * n);
    l = i & 1;
    for (j = l; j <= k; j += 2) {
      if (j == 0)
        ar[j] = ar[j + 1] + A[1][i % n];
      else if (j + 2 > k)
        ar[j] = ar[j - 1] + A[0][i % n];
      else
        ar[j] = min(ar[j - 1] + A[0][i % n], ar[j + 1] + A[1][i % n]);
    }
    if (i == m) {
      printf("%d\n", ar[0] + ans);
      return 0;
    }
  }
  return 0;
}
