#include <bits/stdc++.h>
using namespace std;
int n, a[30], b[30], c[30], res;
int main() {
  cin >> n;
  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];
  for (int i = 1; i <= n; ++i) {
    res += b[a[i]];
    if (i < n && a[i + 1] - a[i] == 1) res += c[i];
  }
  cout << res << '\n';
  return 0;
}
