N = int(input())
A = list(map(int, input().split()))
B = list(map(int, input().split()))
C = list(map(int, input().split()))

count = 0
prev = len(C)
for i in range(N):
  count += B[A[i]-1]
  if prev < len(C):
    count += C[prev]
  prev = A[i] - 1
print(count)