rt
第二个点 TLE 了我还能理解,后面会优化,关键是第一个点为什么 WA 了??
#include<bits/stdc++.h>
using namespace std;
const int N=1e3+1;
int t,k;
int main(){
ios::sync_with_stdio(false);
cin.tie(0),cout.tie(0);
cin>>t;
while(t--){
int n,m,a;
cin>>n>>m>>a;
int a1,a2,b1,b2,c1,c2;
bool st=true;
for(int i=0;i<=m;i++){
for(int j=0;j<=n;j++){
if(i*j==a){
printf("Case #%d: 0 0 0 %d %d %d\n",++k,i,i,j);
st=0;
break;
}
}
if(!st){
break;
}
}
if(st){
printf("Case #%d: IMPOSSIBLE\n",++k);
}
}
return 0;
}