#include <bits/stdc++.h>
using namespace std;
long long visit[200], ar[200], b[200], c[200], len = 0, ans1 = 0;
map<string, int> mp;
string s, ss[100000];
vector<int> ve;
int main() {
  long long i, j, k, n, ans = 0;
  cin >> n;
  for (i = 1; i <= n; i++) cin >> ar[i];
  for (i = 1; i <= n; i++) cin >> b[i];
  for (i = 1; i <= n - 1; i++) cin >> c[i];
  for (i = 1; i <= n; i++) {
    ans += b[ar[i]];
    if (visit[ar[i] - 1] == 1) ans += c[ar[i] - 1];
    visit[ar[i]] = 1;
  }
  cout << ans << endl;
  return 0;
}
