human
Anton is playing a very interesting computer game, but now he is stuck at one of the levels. To pass to the next level he has to prepare n potions.

Anton has a special kettle, that can prepare one potions in x seconds. Also, he knows spells of two types that can faster the process of preparing potions.

  1. Spells of this type speed up the preparation time of one potion. There are m spells of this type, the i-th of them costs bi manapoints and changes the preparation time of each potion to ai instead of x. 
  2. Spells of this type immediately prepare some number of potions. There are k such spells, the i-th of them costs di manapoints and instantly create ci potions. 


Anton can use no more than one spell of the first type and no more than one spell of the second type, and the total number of manapoints spent should not exceed s. Consider that all spells are used instantly and right before Anton starts to prepare potions.

Anton wants to get to the next level as fast as possible, so he is interested in the minimum number of time he needs to spent in order to prepare at least n potions.

Input

The first line of the input contains three integers n, m, k (1 ≤ n ≤ 2·109, 1 ≤ m, k ≤ 2·105) — the number of potions, Anton has to make, the number of spells of the first type and the number of spells of the second type.

The second line of the input contains two integers x and s (2 ≤ x ≤ 2·109, 1 ≤ s ≤ 2·109) — the initial number of seconds required to prepare one potion and the number of manapoints Anton can use.

The third line contains m integers ai (1 ≤ ai < x) — the number of seconds it will take to prepare one potion if the i-th spell of the first type is used.

The fourth line contains m integers bi (1 ≤ bi ≤ 2·109) — the number of manapoints to use the i-th spell of the first type.

There are k integers ci (1 ≤ ci ≤ n) in the fifth line — the number of potions that will be immediately created if the i-th spell of the second type is used. It's guaranteed that ci are not decreasing, i.e. ci ≤ cj if i <...
assistant
#Here is the Python program you requested.

class First:
    def __init__(self, seconds, cost):
        self.seconds = seconds
        self.cost = cost
class Second:
    def __init__(self, numCreated, cost):
        self.numCreated = numCreated
        self.cost = cost

def solve():
    potionCount, firstCount, secondCount = map(int, raw_input().split())
    secondsOne, manaPoints = map(int, raw_input().split())
    first = list()
    a, b = list(map(int, raw_input().split())), list(map(int, raw_input().split()))
    for i in range(firstCount):
        first.append(First(a[i], b[i]))
    first.append(First(secondsOne, 0))
    second = [Second(0, 0)]
    a, b = list(map(int, raw_input().split())), list(map(int, raw_input().split()))
    for i in range(secondCount):
        second.append(Second(a[i], b[i]))
    res = int(1e20)
    for f in first:
        low = 0
        high = len(second) - 1
        while low < high:
            mid = (low + high + 1) / 2
            if f.cost + second[mid].cost > manaPoints:
                high = mid - 1
            else:
                low = mid
        if f.cost + second[low].cost <= manaPoints:
            moar = max(0, potionCount - second[low].numCreated)
            time = moar * f.seconds
            res = min(res, time)
    print(res)
solve()