代码太难写
代码太难写
全部文章
分类
归档
标签
去牛客网
登录
/
注册
代码太难写的博客
全部文章
(共196篇)
题解 | #多态实现求面积体积#
#include<bits/stdc++.h> using namespace std; class rectangle{ private: int length,width; public: rectangle(int x,int y){ length=x; w...
2023-05-25
0
279
题解 | #子类中调用父类构造#
#include <iostream> using namespace std; class Base { private: int x; int y; public: Base(int x, int y) { ...
2023-05-25
0
241
题解 | #重写子类计算逻辑#
#include <iostream> using namespace std; class Base { private: int x; int y; public: Base(int x, int y) { this->x = x;...
2023-05-25
0
269
题解 | #计算小球走过的路程和反弹高度#
#include <cstdio> #include <iostream> #include <iomanip> using namespace std; int main() { // 下落的高度和落地的次数 double h,n,origi...
2023-05-25
0
252
题解 | #重载小于号#
#include <iostream> using namespace std; class Time { public: int hours; // 小时 int minutes; // 分钟 Time() ...
2023-05-25
0
283
题解 | #友元类#
#include<bits/stdc++.h> using namespace std; class phone{ // write your code here...... friend class myphone; private: int price; public: ...
2023-05-25
0
244
题解 | #简单运算#
#include <iostream> using namespace std; int main() { // write your code here...... int a,b; cin>>a>>b; if(a>b)...
2023-05-24
0
251
题解 | #友元全局函数#
#include <iostream> using namespace std; class Person { // write your code here...... friend void showAge(Person& p); public: ...
2023-05-24
0
267
题解 | #复制部分字符串#
#include <iostream> using namespace std; int main() { char str[30] = { 0 }; cin.getline(str, sizeof(str)); int m; cin >>...
2023-05-15
1
279
题解 | #数组类的拷贝构造函数#
#include<bits/stdc++.h> using namespace std; class Array{ private: int n;//数组大小 int *a;//数组 public: Array(){ cin>>n; a=ne...
2023-05-15
3
323
首页
上一页
1
2
3
4
5
6
7
8
9
10
下一页
末页