n = int(input())
a = list(map(lambda x: int(x), input().split()))
b = list(map(lambda x: int(x), input().split()))
c = list(map(lambda x: int(x), input().split()))
ans = 0
pre_a = 0
for i in a:
    ans += b[i-1]
    if i == pre_a + 1 :
        ans += c[pre_a-1]
    pre_a = i
print(ans)
