Mystery 12

3.7

33 votes
Problem

Solve the mystery.

INPUT :
First line contains T No. of test cases.
Each test case contains two lines. First line contains two space separated integers ( N and K). Second line contains N space separated integers A [i].

OUTPUT :
Print the solution of this mystery in each line.

CONSTRAINTS :
1 ≤ T ≤ 100
1 ≤ N ≤ 105
1 ≤ K ≤ N
0 ≤ A[ i ] ≤ 109

Problem Setter : Rajan Kasodariya

Time Limit: 1
Memory Limit: 256
Source Limit:
Editor Image

?