N = int(input()) A = list(map(int, input().split(' '))) M = int(input()) B = list(map(int, input().split(' '))) sum = [0 for _ in range(1<