4.17&4.18
来源:互联网 发布:小米4能用移动4g网络吗 编辑:程序博客网 时间:2024/05/28 11:28
#include<iostream>#include<string>using namespace std;class student{public:void show(){cout<<name<<" "<<number<<" "<<test<<endl;}student(string x,int y,int z);friend void max(student *i);private:string name;long int number;int test;};student::student(string x,int y,int z){name=x;number=y;test=z;}void max(student *i){int t,e=0,big=i[0].test;for(t=1;t<6;t++){if(big<i[t].test){big=i[t].test;e=t;}}cout<<"六位同学中成绩最高的是:"<<i[e].name<<endl; cout<<"他的成绩是"<<big<<endl; }int main(){student st1[6]={student("liming",20141143,99),student("lihong",20141144,98),student("lihan",20141165,57),student("wanghan",20141161,88),student("mingming",201411166,87),student("jiangming",20141152,68)};student *p;p=st1;p+=1;p->show();p=p+2;p->show();p=p+2;p->show();max(st1);return 0;}
0 0
- 4.17 4.18
- 4.17-4.18
- 4.17&4.18
- 【计划】4.17-4.18。Fight~!
- 作业4.17 4.18
- C++作业4.17与4.18合成版
- 4.17
- 4.17
- 4.17
- 4.17
- 4.17
- 4.17
- 4.17
- 4.17
- 4.17
- 4.17
- 4.17
- 4.17
- 修改 openstack 中 nova boot 创建实例只能在10个以内的限制
- 指针函数与函数指针的区别
- 什么是DSL
- linux下iptraf和netperf的应用
- 百度新接口,让网页秒收
- 4.17&4.18
- list_style li 的点
- ios 直角和圆角 并存
- Count and Say
- NSString什么时候用copy,什么时候用strong
- FrameLayout(框架布局)
- PullToRefreshListView局部刷新
- list_style
- iOS画图 在控件中画图