2017年3月7日
摘要: #include<iostream>using namespace std; int main(){ int l;//数组长度 cin>>l;//输入数组长度 int *p=new int[l];//定义动态数组 for(int i=0;i<l;i++)//输入数组的元素 { cin>>p[i]; 阅读全文
posted @ 2017-03-07 21:51 热血码农 阅读(50) 评论(0) 推荐(0) 编辑
摘要: #include<iostream>using namespace std; int main(){ int l;//数组长度 cin>>l;//输入数组长度 int *p=new int[l];//定义动态数组 for(int i=0;i<l;i++)//输入数组的元素 cin>>p[i]; in 阅读全文
posted @ 2017-03-07 21:51 热血码农 阅读(59) 评论(0) 推荐(0) 编辑
摘要: #include<iostream>using namespace std; int main(){ int n,m=1;//n为步数,m为方法数 cin>>n; int one=1,two=0;//one为当前步数最后一步为1的方法数,two为当前步数最后一步为2的方法数 for(int i=1; 阅读全文
posted @ 2017-03-07 21:51 热血码农 阅读(84) 评论(0) 推荐(0) 编辑