解题思路:
注意事项:只因你太美
参考代码:
#include <iostream>
using namespace std;
int main(int argc, char** argv) {
int x,y,a,b,c;
cin>>x;
c=x/4;
y=x%4;
switch(y){
case 0:cout<<0<<" "<<0<<" "<<c<<endl;break;
case 1:cout<<0<<" "<<1<<" "<<c-1<<endl;break;
case 2:cout<<1<<" "<<0<<" "<<c-1<<endl;break;
case 3:cout<<1<<" "<<1<<" "<<c-2<<endl;break;
}
return 0;
}
0.0分
4 人评分