上一页 1 ··· 26 27 28 29 30
摘要: 1 #include<iostream> 2 using namespace std; 3 class BaseClass 4 { 5 public: 6 BaseClass() 7 { 8 cout<<"构造基类对象"<<endl; 9 } 10 }; 11 class DerivedClass: 阅读全文
posted @ 2023-04-21 22:23 Code13 阅读(80) 评论(0) 推荐(0) 编辑
摘要: 1 #include<iostream> 2 using namespace std; 3 int main() 4 { 5 int N,a,b,c,i,n,sum=0; 6 cin>>N;cout<<endl; 7 8 for(i=0;i<N;i++) 9 { 10 cin>>a>>b;cout< 阅读全文
posted @ 2023-04-20 21:25 Code13 阅读(12) 评论(0) 推荐(0) 编辑
摘要: 1 #include<iostream> 2 using namespace std; 3 int main() 4 { 5 int x; 6 cin>>x; 7 cout<<"gong xi ni kao le 90 fen!"; 8 return 0; 9 } 1 #include<iostre 阅读全文
posted @ 2023-04-19 21:48 Code13 阅读(20) 评论(0) 推荐(0) 编辑
摘要: 1 #include<iostream> 2 #include<string> 3 using namespace std; 4 class people{ 5 protected: 6 int age;string name; 7 public: 8 people(){}; 9 people(in 阅读全文
posted @ 2023-04-18 22:39 Code13 阅读(104) 评论(0) 推荐(0) 编辑
摘要: 求多边形的面积 1 #include<iostream> 2 using namespace std; 3 class CPolygon{ 4 protected: 5 int width,height; 6 public: 7 void set_values(int a,int b) 8 { 9 阅读全文
posted @ 2023-04-17 19:59 Code13 阅读(55) 评论(0) 推荐(0) 编辑
摘要: 1 #include<iostream> 2 using namespace std; 3 int main() 4 { 5 char a,N,Y; 6 while(1){ 7 8 cout<<"现在正在下雨吗?"<<endl; 9 cout<<"请输入N或Y:"; 10 cin>>a; 11 if 阅读全文
posted @ 2023-04-13 22:03 Code13 阅读(10) 评论(0) 推荐(0) 编辑
摘要: 1 #include<iostream> 2 using namespace std; 3 int main() 4 { 5 int x; 6 cout<<"你考试考了多少分:"<<endl; 7 cin>>x; 8 if(x<=100&&x>=90) 9 cout<<"优"<<endl; 10 e 阅读全文
posted @ 2023-04-12 23:53 Code13 阅读(12) 评论(0) 推荐(0) 编辑
上一页 1 ··· 26 27 28 29 30