C++
文章平均质量分 66
呐喊熊猫
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
汉诺塔问题
#include using namespace std; int i=1; int move(char from,char to) { cout i++; return 0; } int hannuota(int n,int a,int b,int c) { if (n==1) move(a,c); else { hannuota(n-1,a,c,b); move原创 2013-10-15 14:27:41 · 457 阅读 · 0 评论 -
统计学生课程平均分的程序
#include #include #define num1 1 //学生的个数 #define num2 3 //科目数量 using namespace std; struct student { char id[11]; char name[9]; float score[3]; float average; }; int main() { student原创 2013-10-15 20:49:05 · 1453 阅读 · 0 评论 -
单词统计
1原创 2013-10-15 22:38:32 · 435 阅读 · 0 评论 -
计算一元二次方程的程序
#include #include using namespace std; int main() { double a,b,c,x1,x2; cout cin>>a>>b>>c; double deta=b*b-4*a*c; if (a==0&&b==0) { cout } else if (a==0) { cout } else if (b==0)原创 2013-10-21 20:35:08 · 1080 阅读 · 0 评论 -
输出*的图案
#include using namespace std; int tuan1() { for (int i = 1; i { cout for (int j = 0; j { cout } cout } return 0; } int tuan2() { for (int i = 1; i { for (int j = 1; j { c原创 2013-10-21 22:35:17 · 724 阅读 · 0 评论 -
生日是星期几,输入公历,输出星期几
#include #include using namespace std; int main() { int year,month,day,total; cout cin>>year>>month>>day; year--; total=year*365; for (int i = 1; i { if (i%4==0&&i%100!=0||i%400==0) {原创 2013-10-21 21:29:04 · 656 阅读 · 0 评论
分享