#include <bits/stdc++.h>
int main() {
  int i;
  int n;
  int total = 0;
  int *a, *b, *c;
  scanf("%d", &n);
  a = (int *)malloc(sizeof(int) * n);
  b = (int *)malloc(sizeof(int) * n);
  c = (int *)malloc(sizeof(int) * n);
  for (i = 0; i < n; i++) {
    scanf("%d", &a[i]);
  }
  for (i = 0; i < n; i++) {
    scanf("%d", &b[i]);
  }
  for (i = 0; i < n - 1; i++) {
    scanf("%d", &c[i]);
  }
  for (i = 0; i < n; i++) {
    if (i == 0) {
      total += b[(a[i] - 1)];
    } else {
      total += b[(a[i] - 1)];
      if (a[i] != n) {
        total += c[(a[i] - 1)];
      }
    }
  }
  printf("%d", total);
  free(a);
  free(b);
  free(c);
}
