using System;
using System.Linq;

namespace ConsoleApp2
{
    class Program
    {
        static void Main(string[] args)
        {
            //input
            int N = Convert.ToInt32(Console.ReadLine());
            int[] A = Console.ReadLine().Split(" ").Select(t => Convert.ToInt32(t)).ToArray();
            int[] B = Console.ReadLine().Split(" ").Select(t => Convert.ToInt32(t)).ToArray();
            int[] C = Console.ReadLine().Split(" ").Select(t => Convert.ToInt32(t)).ToArray();

            int sum = 0;
            int before = -1;
            for(int i = 0; i < N; i++)
            {
                sum += B[A[i]-1];
                if(A[i] == before + 1)
                {
                    sum += C[before-1];
                }
                before = A[i];
            }

            Console.WriteLine(sum);
        }
    }
}
