Why this code is showing wrong answer

#include
using namespace std;
void shopping(int A[], int N, int Q){
for( int i = 0; i < Q; i++){
int money, no ;
cin>> money >> no;
int count = 0;
for( int j = 0; j < N; j++ ){
if( money % A[j] == 0 ){
count++;
}
}
if( count == no ){
cout <<“Yes\n”;
}
else{
cout << “No\n”;
}
}
}
int main() {
int n;
cin >> n;
int a[n];
for( int i = 0; i < n; i++){
cin >> a[i];
}
int q;
cin >> q;
shopping(a,n,q);
return 0;
}

hi @akki56756_bab14f919dbad123
refer this -->

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.