#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, sum = 0;
  cin >> n;
  int a[n], b[n], c[n - 1], d, coun = 0;
  for (int i = 1; i <= n; i++) {
    cin >> a[i];
  }
  for (int i = 1; i <= n; i++) {
    cin >> b[i];
  }
  for (int i = 1; i <= n - 1; i++) {
    cin >> c[i];
  }
  int u = 0;
  for (int i = 1; i <= n; i++) {
    u = u + b[a[i]];
  }
  for (int i = 1; i <= n; i++) {
    for (int j = i + 1; j <= n; j++) {
      if (a[j] - a[i] == 1) {
        d = c[a[i]];
        sum = sum + d;
        coun++;
      }
    }
  }
  cout << u + sum << endl;
}
