n = int(raw_input())
a = map(int,raw_input().split())
b = map(int,raw_input().split())
c = map(int,raw_input().split())
res = 0
prev = -1
for x in a:
	res += b[x-1]
	if x-1 == prev:
		res += c[x-2]
	prev = x
print res