import numpy as np

def main():
    n=int(input())
    A=list(map(int,input().split()))
    B=list(map(int,input().split()))
    C=list(map(int,input().split()))
    
    sum=0
    for i in range(n):
        sum+=B[A[i]-1]
        if i!=0:
            dif=abs(A[i]-A[i-1])
            if dif==1:
                index=min(A[i],A[i-1])-1
                sum+=C[index]
    print(sum,end="")



if __name__ == '__main__':
    main()  