N = int(input())
cook_list = list(map(int,input().split()))
satisfy_list = list(map(int,input().split()))
plus_satisfy_list = list(map(int,input().split()))

sum_point = 0
prev_num = 0

for now_num in cook_list:
  sum_point += satisfy_list[now_num - 1]
  if (now_num - prev_num) == 1:
    sum_point += plus_satisfy_list[prev_num - 1]
  prev_num = now_num
  
print(sum_point)