You are given two arrays, \(A\) and \(B\) of length \(N\). In one operation, you can swap \(A[i]\) and \(B[i]\). Find the maximum sum of \(A\) after performing at most \(K\) operations.
Input format
Output format
For each test case, print the maximum sum of \(A\) after performing at most \(K\) operations in a new line.
Constraints
\(1 \leq T \leq 10 \\ 1 \leq K \leq N \leq 10^5 \\ 0 \leq A[i], B[i] \leq 10^3\)
For test case \(1\): We can perform the operations at indexes 2, 4, and 5 (1-based indexing). \(A\) becomes \([1, 4, 1, 6, 5].\) Hence, the answer is \(17\).
For test case \(2\): We can perform the operations at index 1 (1-based indexing). \(A\) becomes \([3, 5, 1]\). Hence, the answer is \(9\).