- 博客(8)
- 资源 (1)
- 问答 (1)
- 收藏
- 关注
原创 [C++]菱形图案
#include#include#includeusing namespace std;int main(){ for (int i = 0; i < 7; i++) { for (int j = 0; j < 16 - i; j++) cout << ' '; for (int j = 0; j < 2*i + 1; j++) cout << '*';
2015-11-26 16:22:03 5468
原创 [C++]分数计算器(四则运算)class
//main.cpp#include#include"Rational.h"using namespace std;void main(){ Rational calculate; calculate.Set(); calculate.Judge(); return;}//Rational.hclass Rational{public: void Set()
2015-11-22 22:07:29 2732
原创 [C++]小数转化为分数(class)
/*Rational.cpp*/#include "Rational.h"#include#include#includeusing namespace std;void Rational::change(string num, int fz, int fm){ bool flag = 0; char ch; for (int i = 0; i < num.length(
2015-11-15 20:24:01 6362 1
原创 [C++]时间格式转换器24转为12(class)
//TIme.hclass TimeType{public: int hour; int minute; int second; void WriteAMPM(int &hour,int &minute,int &second);private:};//TIme.cpp#include "TIme.h"#includeusing namespace std;void
2015-11-15 12:22:31 723
原创 [C++]查找文件中的一串字符串
#include#include#includeusing namespace std;void main(){ cout << "**************************************************search engine*******************************************************" << end
2015-11-15 10:02:10 2652
原创 [C++]百钱买百鸡
#include#includeusing namespace std;void main(){ int gj, mj, xj; for (gj = 1; gj < 15; gj++) { for (mj = 1; mj <= 20; mj++) { for ( xj = 3; xj <=100; xj+=3) { if ((gj+mj+xj==100
2015-11-14 17:32:54 1457 3
原创 [C++]sales-reporter
1.使用前需要把数据文件放置在exe程序同一文件夹内。2.数据文件内容可修改,有且仅有8对数据,否则会报错(已预置sales.txt文件,格式可参照修改,第一列为itemNumber,第二列为对应的unitePrice)3.双击exe运行,根据提示输入数据文件名称,存放结果数据文件名称,salesperson lastname(内置z1-z10),item number,quantity。
2015-11-14 11:17:41 320
原创 [c++]万年历
#include#includeusing namespace std;void main(){ int monthDay[12] = { 31,0,31,30,31,30,31,31,30,31,30,31 };\\确定每个月的天数 cout << "please enter the year" << endl; int year; cin >> year; if (y
2015-11-14 11:16:51 605
strcpy的实现问题。。。。
2016-01-02
TA创建的收藏夹 TA关注的收藏夹
TA关注的人