Run ID:135168

提交时间:2025-11-02 17:17:26

#include <bits/stdc++.h> using namespace std; int main(){ int N; cin>>N; int cnt=0; for(int x=0;x<=N;x++){ for(int y=0;y<=N-x;y++){ int z=N-x-y; if(3*N==x*15+y*9+z){ cnt++; cout<<cnt<<": "<<x<<","<<y<<","<<z<<endl; } } } if(cnt==0){ cout<<"None"; } return 0; }