1407241730-hd-母牛的故事.cpp
来源:互联网 发布:手机sd卡删除数据恢复 编辑:程序博客网 时间:2024/05/29 08:40
#include<stdio.h>
int main()
{
int str[60];
int n;
int i,j;
str[0]=0;
str[1]=1;
str[2]=2;
str[3]=3;
str[4]=4;
for(i=5;i<55;i++)
str[i]=str[i-1]+str[i-3];
while(scanf("%d",&n),n)
{
printf("%d\n",str[n]);
}
return 0;
}
int main()
{
int str[60];
int n;
int i,j;
str[0]=0;
str[1]=1;
str[2]=2;
str[3]=3;
str[4]=4;
for(i=5;i<55;i++)
str[i]=str[i-1]+str[i-3];
while(scanf("%d",&n),n)
{
printf("%d\n",str[n]);
}
return 0;
}
0 0
- 1407241730-hd-母牛的故事.cpp
- hd 2018 母牛的故事
- 母牛的故事 hd 2018
- 母牛的故事
- hdu_2018_母牛的故事
- HDOJ2018 母牛的故事
- 母牛的故事
- 2018 母牛的故事
- HDOJ2018 母牛的故事
- hdu2018母牛的故事
- HDU_2018 母牛的故事
- hdoj_2018 母牛的故事
- 母牛的故事
- 母牛的故事
- hdu-母牛的故事
- 母牛的故事
- 母牛的故事
- 母牛的故事
- rewrite指令解析
- Redis学习手册(List数据类型)
- MyBatis+MySQL 返回插入的主键ID
- Nova 各个组件介绍以及功能分析(逻辑架构,运行架构,开发架构以及数据库)
- Android 中tomcat搭建本地服务器 实现apk更新下载
- 1407241730-hd-母牛的故事.cpp
- Redis学习手册(Set数据类型)
- static的作用
- MediaScanner,MediaProvider,MediaStore等接口
- Redis学习手册(Hashes数据类型)
- 关于野指针
- Redis学习手册(Sorted-Sets数据类型)
- IT忍者神龟之 遍历Map的四种方法
- 设计模式中组合(Compose)和聚合(Aggregate)的关系