Your are given two sequences

and

.You need to answer
%20%5Ctimes%20sum(b_%7Bl%20%5Cdots%20r%7D)%5C%7D)
。
Where min(a) means the minimal value of every element of sequence a, sum(a) means the sum of every element of sequence a .
输入描述:
The first line contains an integer n .
The second line contains n integers meaning
.
The third line contains n integers meaning
.
输出描述:
An integer meaning the answer.
备注:
For all test datas,
.