- 博客(8)
- 收藏
- 关注
转载 C++实验6
#include <iostream>#include <fstream> #include <string>#include <cstdlib>using namespace std;int main() { ofstream fout; fout.open("3.txt",ios_...
2019-06-11 20:29:00
167
转载 实验5
#pragma once#include<string>using namespace std;class MachinePets{public: MachinePets(const string s); ~MachinePets(); const string getNickname(); virtual ...
2019-06-03 23:22:00
133
转载 c++实验4
project1:#ifndef BATTERY_H#define BATTERY_Hclass Battery {public: Battery(int batterySize0 = 70); Battery(const Battery& b0); int getbattery();private: int b...
2019-05-18 23:24:00
149
转载 期中考试
编程题1// 工具包头文件,用于存放函数声明 // 函数声明 bool isLeap(int);utils.h// 功能描述: // 判断year是否是闰年, 如果是,返回true; 否则,返回false bool isLeap(int year) { if( (year % 4 == 0 && ...
2019-04-30 14:57:00
128
转载 c++实验3
1.graph类#ifndef GRAPH_H#define GRAPH_H// 类Graph的声明class Graph {public: Graph(char ch, int n); // 带有参数的构造函数 void draw(); // 绘制图形private: char symbol; int size;...
2019-04-22 17:40:00
101
转载 课堂练习Complex类
Complex类 1 #include<iostream> 2 #include<cmath> 3 using namespace std; 4 class Complex { 5 public: 6 Complex(double nreal = 0.0, double nimaginary = 0.0); 7 Co...
2019-04-02 19:37:00
208
转载 c++实验2
函数重载编程练习 1 #include<iostream> 2 using namespace std; 3 struct complex 4 { 5 double real; 6 double imaginary; 7 }; 8 int add(int ,int ); 9 double add(double ,doub...
2019-03-25 21:25:00
123
转载 c++实验1
2-28 1 #include<iostream> 2 #include<stdlib.h> 3 using namespace std; 4 int main(){ 5 char a; 6 while(true){ 7 cout<<"Menu:A(dd) D(elet) S(ort) Q(uit...
2019-03-17 19:22:00
119
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人