摘要: #include<iostream>using namespace std;int main(){ int Line1[]={1,0,0}; int Line2[]={0,1,0}; int Line3[]={0,0,1}; int *pLine[3]={line1,line2,line3}; co 阅读全文
posted @ 2023-04-16 20:57 不会JAVA的小袁 阅读(10) 评论(0) 推荐(0)
摘要: #include<iostream>using namespace std;void rowSum(int a[][4],int nRow){ for(int i=0;i<nRow;i++){ for(int j=1;j<4;j++) a[i][0]+=a[i][j]; }}int main(){ 阅读全文
posted @ 2023-04-16 20:44 不会JAVA的小袁 阅读(13) 评论(0) 推荐(0)
摘要: #include<iostream>using namespace std;int main(){ int a[10],b[10]; for(int i=0;i<0;i++){ a[i]=i*2-1; b[10-i-1]=a[i]; } for(const auto &e:a) cout<<e<<" 阅读全文
posted @ 2023-04-16 20:32 不会JAVA的小袁 阅读(9) 评论(0) 推荐(0)
摘要: #include<iostream>#include<cmath>using namespace std;class Point{ public: Point(int x=0,int y=0):x(x),y(y){} int getX(){return x; } int getY({retuen y 阅读全文
posted @ 2023-04-16 20:21 不会JAVA的小袁 阅读(10) 评论(0) 推荐(0)
摘要: #include<iostream>using namespace std;class A{ public: A(int i); void print(); private: const int a; static const int b;};const intA::b=10;A::A(int i) 阅读全文
posted @ 2023-04-16 20:10 不会JAVA的小袁 阅读(11) 评论(0) 推荐(0)