Help me in solving CHEFSQ problem

My issue

cook your dish here

v=int(input())
for i in range(v):
n1=int(input())
lst1=list(map(int,input().split()))
n2=int(input())
lst2=list(map(int,input().split()))
for i in lst2:
if i not in lst1:
print(“No”)
else:
print(‘Yes’)
WHY IT DOES NOT TAKING INPUT ERROR MESSAGE;-Traceback (most recent call last):
File “/mnt/sol.py”, line 2, in
v=int(input())
^^^^^^^
EOFError: EOF when reading a line

My code

# cook your dish here
v=int(input())
for i in range(v):
    n1=int(input())
    lst1=list(map(int,input().split()))
    n2=int(input())
    lst2=list(map(int,input().split()))
    for i in lst2:
        if i not in lst1:
            print("No")
        else:
            print('Yes')

Problem Link: Chef and his Sequence Practice Coding Problem - CodeChef

@srivarshith
plzz refer the follwing c++ code for better understanding of the logic

#include <bits/stdc++.h>
using namespace std;

int main() {
	// your code goes here
	int t;
	cin>>t;
	while(t--)
	{
	    int n;
	    cin>>n;
	    int a[n];
	    for(int i=0;i<n;i++)
	    {
	        cin>>a[i];
	    }
	    int m;
	    cin>>m;
	    int b[m];
	    for(int i=0;i<m;i++)
	    {
	        cin>>b[i];
	    }
	    int i=0,j=0;
	    while(i<n)
	    {
	        if(a[i]==b[j])
	        {
	            i++;
	            j++;
	        }
	        else
	        i++;
	        if(j==m)
	        break;
	    }
	    if(j==m)
	    cout<<"Yes";
	    else
	    cout<<"No";
	    cout<<endl;
	}

}

I got the same error. I don’t know the reason why. do tell me if you got it cleared