Good Grid - Problem from january lunchtime

Can anyone help me out with the Good Grid problem which was asked in lunchtime 2021.
Here is the problem link: CodeChef: Practical coding for everyone

#include <bits/stdc++.h>
#define ll long long int
using namespace std;

int main()
{
ll t;
cin>>t;
while(t–){
ll n,x; cin>>n>>x;
if(x%n == 0) cout << “Yes” << “\n”;
else cout << “No” << “\n”;
}
return 0;
}
This was my code for the problem.

Logic is incorrect

Can you please explain the logic for this code?