{"trustable":true,"sections":[{"title":"","value":{"format":"MD","content":"Chefland has all the cities on a straight line. There are $N$ cities in Chefland numbered $1$ to $N$. City $i$ is located at coordinate $x_i$ on the x-axis. Guru wants to travel from city $A$ to city $B$. He starts at time t\u003d0. He has following choices to travel.\r\n\r\n1. He can walk $1$ metre in $P$ secs.\r\n2. There is a train that travels from city $C$ to city $D$ which travels $1$ metre in $Q$ secs which starts at time t\u003d$Y$ secs. Guru can take the train only at city $C$ and leave the train only at city $D$.\r\n\r\nCan you help Guru find the minimum time he will need to travel from city $A$ to $B$. Note that you cannot board the train after time t \u003d$Y$.\r\n\r\n### Input:\r\n\r\n- First line will contain $T$, number of testcases. Then the testcases follow. \r\n- First line of each testcase contains eight space separated integers $N, A, B, C, D, P, Q, Y $. \r\n- Second line of each testcase contains $N$ space-separated integers with the $i$-th integer representing $x_i$.\r\n\r\n### Output:\r\nFor each testcase, output in a single line containing the minimum travel time.\r\n\r\n### Constraints \r\n- $1 \\leq T \\leq 300$\r\n- $2 \\leq N \\leq 300$\r\n- $-1000 \\leq x_i \\leq 1000$\r\n- $0 \\leq Y \\leq 100000$\r\n- $1 \\leq A,B,C,D \\leq n $\r\n- $A \\neq B$\r\n- $C \\neq D$\r\n- $1 \\leq P, Q \\leq 100$\r\n- $x_i \u003c x_j$ if $i \u003c j$\r\n\r\n\r\n### Sample Input:\r\n1\r\n\r\n4 1 3 2 4 3 2 4\r\n\r\n1 2 3 4\r\n\r\n### Sample Output:\r\n6\r\n\r\n### EXPLANATION:\r\nGuru can walk directly in 6 secs.\r\n\r\nIf Guru takes train, then he will need atleast 11 secs."}}]}