说白了就是循环加递推!
2025-07-24 11:16:57
发布于:浙江
1阅读
0回复
0点赞
#include <bits/stdc++.h>
using namespace std;
int t,x,k;
int main(){
cin>>t;
for(int i=1;i<=t;i++){
cin>>x>>k;
if(k>x){
cout<<"1"<<endl;
}
else{
if(x%k==0){
cout<<"2"<<endl;
}
else{
cout<<"1"<<endl;
}
}
}
return 0;
}
这里空空如也
有帮助,赞一个