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

sat = 0
prev_ryouri = 0

for i in range(n):
  ryouri = A[i] - 1
  sat += B[ryouri]
  if prev_ryouri+1 == ryouri:
    sat += C[prev_ryouri]
    
  prev_ryouri = ryouri


print(sat)