n = int(input())

a = list(map(int, input().split()))
b = list(map(int, input().split()))
c = list(map(int, input().split()))

ans = 0
for i in range(n):
  ai = a[i]
  pre_ai = 0
  if i != 0:
    pre_ai = a[i-1]
    
  ans += b[ai]
  if ai - pre_ai = 1:
    ans += c[pre_ai]
    
print (ans)
  