n = int(input()) size = map(int, input().split()) t, p = map(int, input().split()) print(sum((i+t-1)//t for i in size)) print(n//p,n%p)