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

void solve()
{
int x,y;
scanf("%d%d" , &x , &y);

if(y>=x)
{
	printf("%d" , y);
	return;
}
else{
	

for(int i=x ;  ; i++)
{

    if(i%y==0)
        {
            printf("%d" , i);
            break;
        }
}
}
}

int main() {
	int t=1;
	cin>>t;
	while(t--)
	{
		solve();
		cout<<endl;
	}
	return 0;
}

Copy
AZOZ with an O (EZ Version) TATAKAE
GNU G++17
2093 ms
1.2 MB
Time Limit Exceeded