- 博客(8)
- 收藏
- 关注
原创 C语言:双重指针对数组排序;
#include"stdio.h"void sort(int **p,int n){ int temp; int i,j; for (i=0;i for(j=i+1;j if(*p[i]>*p[j]) { temp=*p[i];
2016-04-27 22:09:35 712
原创 判断摩天是该年第几天【数组】;
#include using namespace std;struct ymd{ int year; int month; int day;};int days(struct ymd date){ int a[12]={31,29,31,30,31,30,31,31,30,31,30,31};
2016-04-27 22:07:27 206
原创 递归函数秋x的y次方
烟台大学计算机与控制工程学院154-2张全伟17853535839201558504210#include using namespace std;int p(int x,int y){ int a=1; while (n--) a=a*x; return a;}
2016-04-19 22:37:28 632
原创 确定某年某月某天是该年的第几天
#include using namespace std;struct Date{int year;int month;int day;};int main(){ Date d; cin>>d.year>>d.month>>d.day; int temp; if(d.year%4==0||d.year%400==0&&d.year%1
2016-04-13 22:22:55 481
原创 用类求三角形的周长与面积
#include #includeusing namespace std;class triangle{public: void setABC(double x,double y,double z); double perimeter(); double area();private: double a,b,c;}
2016-04-13 22:19:53 1499
原创 华氏温度转化为摄氏温度
#include using namespace std;double SSD(double c);int main(){ double F; cin>>F; double C; C=SSD(F); cout return 0;}double SSD(double f){
2016-04-06 21:58:10 741
原创 输入成绩查看等级
#include using namespace std;int main(){ int n; cin>>n; if (n>=90&&n cout if (n>=80&&n cout if (n>=70&&n cout if (n>=60&&n
2016-04-04 20:44:51 442
原创 求x的n次方
#include using namespace std;double p(int x,int n){ int a=1; while (n--) a*=x; return a;}int main(){ int m,w; cin>>m>>w; int sun; su
2016-04-04 20:43:32 526
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人