输出:1 1 2 3 5
int[] num = new int[count];
num[0] = num[1] = 1;
for (int i = 2; i < count; i++) {
num[i] = num[i - 1] + num[i - 2];
}
for (int j = 0; j < count; j++){
system.out.print(num[j] + " ");
}
}
}
如对本文有疑问, 点击进行留言回复!!
关于在IDEA中SpringBoot项目中activiti工作流的使用详解
视频编辑工具ACDSee Luxea Video Editor安装及激活图文教程
java spring整合junit操作(有详细的分析过程)
网友评论