n=int(input())
a,b,c=[list(map(int,input().split())) for _ in range(3)]
s=0
before= n
for i in range(n):
      s+=b[a[i]-1]
      if a[i]==before+1:
            s+=c[a[i-1]-1]
      before=a[i]
print(s)
