2023-07-26 14:46发布
没有的,别上当希望能帮到你,如果你的问题解决了,麻烦点一下采纳,谢追问对刷那种呢,以前我弄过。但是忘记怎么弄了#p#哩 喕 都 苛 以 王元ewy.baidu/
struct Student { int num; string name; int lan,mat,eng,total; }; void main() { int n,i,total,min; Student person[256]; cin>>n; for ( i=0;i>...... for ( i=0;i<n;i++ ) person[i].total=person[i].lan+person[i].mat+person[i].eng; min=person[0].total; for ( i=1;i<n;i++ ) if ( person[i].total<min ) min=person[i].total; for ( i=0;i<n;i++ ) if ( person[i].total==min ) cout<<person[i].num<<" "<<person[i].name<<" "<<person[i].total<<endl; }追答
完起来不卡的,自己去了就知道了 ditu/www.20fire.com?moJs
最多设置5个标签!
struct Student { int num; string name; int lan,mat,eng,total; }; void main() { int n,i,total,min; Student person[256]; cin>>n; for ( i=0;i>...... for ( i=0;i<n;i++ ) person[i].total=person[i].lan+person[i].mat+person[i].eng; min=person[0].total; for ( i=1;i<n;i++ ) if ( person[i].total<min ) min=person[i].total; for ( i=0;i<n;i++ ) if ( person[i].total==min ) cout<<person[i].num<<" "<<person[i].name<<" "<<person[i].total<<endl; }追答
一周热门 更多>