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

total = 0
pos = 0
while pos < N:
	posB = A[pos] -1
	total = total + B[posB]
	if A[pos + 1] - A[pos] == 1:
		posC = A[pos + 1] - 2
		total = total + C[posC]
	pos += 1
print(total)
