use std::io::prelude::*;
use std::io::stdin;
use std::str::FromStr;

fn main() {
    let n: usize = read();
    let a: Vec<i32> = (0..n).map(|_| read()).collect();
    let b: Vec<i32> = (0..n).map(|_| read()).collect();
    let c: Vec<i32> = (0..n - 1).map(|_| read()).collect();

    let mut prev_menu_number = a[0];
    let mut sum = 0;

    for &a_i in a.iter() {
        if prev_menu_number + 1 == a_i {
            dbg!("HI");
            sum += c[prev_menu_number as usize - 1];
        }
        sum += b[a_i as usize - 1];
        prev_menu_number = a_i;
    }

    println!("{}", sum);
}

#[allow(dead_code)]
fn read<T: FromStr>() -> T {
    let stdin = stdin();
    let token: String = stdin
        .lock()
        .bytes()
        .map(|b| b.unwrap() as char)
        .skip_while(|c| c.is_whitespace())
        .take_while(|c| !c.is_whitespace())
        .collect();
    token.parse().ok().unwrap()
}
