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