The first line contains the integer N, the number of stickers. N is a positive integer not greater than 32.
The second line contains the price of each sticker.
The third line contains the value of each sticker.
The fourth line contains the integer K.
The fifth line contains the number of stickers Yeonghun initially owns.
The sixth line contains the numbers of the stickers Yeonghun initially owns. If he initially owns 0 stickers, the sixth line is not given.
Each price is a positive integer not greater than 30,000,000. The number of initially owned stickers is an integer from 0 to N, inclusive. K is an integer from 0 to 1,000,000,000, inclusive. Each value is an integer from 1 to 30,000,000, inclusive.