CDZSC_2015寒假新人(2)——数学 D
Description
Input
Output
Print the word "no" if not.
Sample Input
1
2
3
4
5
Sample Output
no
yes
no
no
no
#include<iostream>
#include<cstdio>
#include<cmath>
#include<ctime>
using namespace std;
int a[];
int main()
{
a[]=;
a[]=;
for(int i=;i<;i++)
{
a[i]=(a[i-]+a[i-])%;
}
int n;
//printf("%.2f",(double)clock()/CLOCKS_PER_SEC);
while((scanf("%d",&n))!=EOF)
{
if(a[n]%==)
{
printf("yes\n");
}
else
{
printf("no\n");
}
}
}
CDZSC_2015寒假新人(2)——数学 D的更多相关文章
- CDZSC_2015寒假新人(2)——数学 P
P - P Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64u Submit Status ...
- CDZSC_2015寒假新人(2)——数学 H
H - H Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64u Submit Status ...
- CDZSC_2015寒假新人(2)——数学 G
G - G Time Limit:3000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64u Submit Status ...
- CDZSC_2015寒假新人(2)——数学 C
C - C Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64u Submit Status ...
- CDZSC_2015寒假新人(2)——数学 B
B - B Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64u Submit Status ...
- CDZSC_2015寒假新人(2)——数学 A
A - A Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64u Submit Status ...
- CDZSC_2015寒假新人(1)——基础 i
Description “Point, point, life of student!” This is a ballad(歌谣)well known in colleges, and you mus ...
- CDZSC_2015寒假新人(1)——基础 h
Description Ignatius was born in a leap year, so he want to know when he could hold his birthday par ...
- CDZSC_2015寒假新人(1)——基础 g
Description Ignatius likes to write words in reverse way. Given a single line of text which is writt ...
随机推荐
- Hbase常见异常
1. HBase is able to connect to ZooKeeper but the connection closes immediately hbase(main):001:0> ...
- 初识cross apply & outer apply
1. 2. 3.参考地址: http://blog.csdn.net/htl258/article/details/4537421
- 最大子数组分治方案C++实现
大家好,我是小鸭酱,博客地址为:http://www.cnblogs.com/xiaoyajiang 以下实现最大子数组的分治策略,算法来自<算法导论> #include<iostr ...
- JVM性能调优博客
http://houjixin.blog.163.com/blog/static/35628410201411275719843/ http://blog.csdn.net/lastsweetop/a ...
- Thinkpad E430+CentOS 6.4+ linux-3.10.12内核网卡驱动(无线+有线)配置
配置并编译安装内核模块和内核后,解压附件 firmware.tar.bz2,拷贝其中的rtlwifi文件夹到/lib/firmware下,然后 执行装载内核模块命令: sudo modprobe rt ...
- Shell工具:jsondiff.sh
逻辑很简单,无非就是通过curl在不同的服务器上取得结果集,然后diff即可,不过这里有几点需要注意的地方:首先,JSON就一行,直接 diff会失去意义:其次,JSON中汉字会被编码,不利于查看:另 ...
- OpenWrt刷机
http://blog.163.com/l1_jun/blog/static/14386388201441344612/ http://blog.chinaunix.net/uid-25073805- ...
- proxy 利用get拦截,实现一个生成各种DOM节点的通用函数dom。
const dom = new Proxy({}, { get(target, property) { return function(attrs = {}, ...children) { const ...
- JavaScript获取某年某月的最后一天
JavaScript获取某年某月的最后一天 1.实现源代码 <!DOCTYPE html> <!-- To change this license header, choose Li ...
- ARM9嵌入式学习笔记(1)-Linux命令
ARM9嵌入式学习笔记(1)-Linux命令 实验1-1-2 Linux常见命令使用 添加用户useradd smb; 设置账户密码passwd smb; 切换用户su - root 关机命令shut ...