#include <bits/stdc++.h>
using namespace std;
const int maxn = 50;
int a[maxn], b[maxn], c[maxn], book[maxn];
int main() {
  int n;
  cin >> n;
  for (int i = 1; i <= n; i++) {
    scanf("%d", a + i);
  }
  for (int i = 1; i <= n; i++) {
    scanf("%d", b + i);
  }
  for (int i = 1; i < n; i++) {
    scanf("%d", c + i);
  }
  long long ans = 0;
  for (int i = 1; i <= n; i++) {
    book[a[i]] = 1;
    ans += b[a[i]];
    if (book[a[i] - 1] == 1) {
      ans += c[a[i] - 1];
    }
  }
  printf("%d", ans);
  return 0;
}
