For this Question: Given a sorted array A having N integer elements, find if there exists any pair of elements such that (A[i], A[j]) have the sum equal to X (i < j)The first line of input contains T, denoting the number of testcases. The first line of each test case contains N size of array and X. Second line contains elements of array separated by space.

Constraints:
1 <= T <= 100
1 <= N <= 100000
1 <= X <= 1000
1 <= A[i] <= 1000000For each test case you need to print "Yes" if pair exists otherwise "No".Input:
2
5 4
1 2 3 4 5
5 6
2 3 5 7 8

Output:
Yes
No, I have written this Solution Code: t=int(input())
while(t>0):
	n,s=[int(i) for i in input().split()]
	arr = [int(i) for i in input().split()]
	i=0;j=n-1;c=0;
	while i<j:
		if((arr[i]+arr[j])==s):
			c=1
			break
		if((arr[i]+arr[j])<s):
			i+=1
		else:
			j-=1

	if c==1:
		print("Yes")
		
	else:
		print("No")
	t-=1, In this Programming Language: Python, Now tell me if this Code is compilable or not?