N = int(input())
A = list(map(int,input().split()))
B = list(map(int,input().split()))
C = list(map(int,input().split()))
ans = 0
b = -1
for a in A:
    if b+1==a:ans+=C[b-1]
    b = a
    ans+=B[b-1]
print(ans)