摘要: #include using namespace std;const MAXSIZE=12;const year=3;int main(){char *month[MAXSIZE]={"Janury","February","March","April","May","June","July","August","September","October","November", 阅读全文
posted @ 2013-11-26 16:35 编程的爬行者 阅读(86) 评论(0) 推荐(0) 编辑
摘要: #include using namespace std;const MAXSIZE=12;int main(){char *month[MAXSIZE]={"Janury","February","March","April","May","June","July","August","September","October","November","Decembe 阅读全文
posted @ 2013-11-26 16:20 编程的爬行者 阅读(99) 评论(0) 推荐(0) 编辑
摘要: #include using namespace std;int main(){double count=0;long double cleo=100;long double dap=100;do{cleo+=cleo*0.05;dap+=10;count++;}while(cleo<dap);cout<<"经过"<<count<<"年,cleo的财富 "<<cleo<<" 超过了"<<"dap的财富 "<<dap<&l 阅读全文
posted @ 2013-11-26 14:33 编程的爬行者 阅读(95) 评论(0) 推荐(0) 编辑
摘要: #include using namespace std;const int MAXSIZE=100;int main(){int a[MAXSIZE];int sum=0;for(int i=0;i>a[i];if(a[i]==0)return 0; sum=sum+a[i];cout<<"sum= "<<sum;}system("pause");return 0;} 阅读全文
posted @ 2013-11-26 13:03 编程的爬行者 阅读(90) 评论(0) 推荐(0) 编辑
摘要: #include using namespace std;int main(){int min,max;cout>min;cout>max;int sum=0;for(int i=min;i<=max;i++)sum+=i;cout<<"The sum from min to max: "<<sum<<endl;system("pause");return 0;} 阅读全文
posted @ 2013-11-26 12:36 编程的爬行者 阅读(104) 评论(0) 推荐(0) 编辑