Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
5123 贺昱翔 五个小朋友分巧克力 C++ 解答错误 0 0 MS 252 KB 708 2020-07-27 17:26:12

Tests(0/5):


#include<bits/stdc++.h> using namespace std; int main(){ int n,p1,p2,p3,p4,p5; cin>>n; p1=n;p2=n;p3=n;p4=n;p5=n; //5 p1=p1/2;p2=p2/2;p3=p3/2;p4=p4/2;p5=p1+p2+p3+p4+p5; //cout<<p1<<" "<<p2<<" "<<p3<<" "<<p4<<" "<<p5<<endl; //4 p1=p1/2;p2=p2/2;p3=p3/2;p5=p4/2;p4=p1+p2+p3+p4+p5; //cout<<p1<<" "<<p2<<" "<<p3<<" "<<p4<<" "<<p5<<endl; //3 p1=p1/2;p2=p2/2;p4=p4/2;p5=p5/2;p3=p1+p2+p3+p4+p5; //cout<<p1<<" "<<p2<<" "<<p3<<" "<<p4<<" "<<p5<<endl; //2 p1=p1/2;p3=p3/2;p4=p4/2;p5=p5/2;p2=p1+p2+p3+p4+p5; //cout<<p1<<" "<<p2<<" "<<p3<<" "<<p4<<" "<<p5<<endl; //1 p2=p2/2;p3=p3/2;p4=p4/2;p5=p5/2;p1=p1+p2+p3+p4+p5; cout<<p1<<" "<<p2<<" "<<p3<<" "<<p4<<" "<<p5<<endl; return 0; }


测评信息: