"use strict"
let input = require("fs").readFileSync("/dev/stdin", "utf8");
input = input.split('\n');
let N = input.shift();
let A = input[0].split(' ');
let B = input[1].split(' ');
let C = input[2].split(' ');
//let Ccount = 0;
let ans = 0;
for(let i = 0; i < N*1; i++){
  ans += B[A[i]-1]*1;
  // Cの方の計算
  if(A[i+1]-A[i] == 1){
    ans += C[A[i] -1]*1;
  }
}

console.log(ans)