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