Company: Deutsche_Bank_9_feb
Difficulty: medium
Minimum Adjacent Difference Problem Description You are given two arrays A and B , each containing N integers. You want to minimize the maximum absolute difference between two adjacent integers of the array A (i.e. max i=1 N-1 |A i - A i+1 | ). You can do the following operation at most K times: Choose an index i (1 ≤ i ≤ N) and swap A i , B i . Find the minimum possible value of max i=1 N-1 |A i - A i+1 | . Input Format The first line contains T denoting the number of test cases. The description of T test cases is as follows: For each test case: The first line contains two integers N , K denoting the size of array A and the maximum number of operations to be performed respectively. The second line contains N space-separated integers A 1 , A 2 , ..., A N - denoting the elements of the array A . The third line contains N space-separated integers B 1 , B 2 , ..., B N - denoting the elements of the array B . Output Format For each test case, print the minimum possible value of max i