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 ...
随机推荐
- Linux下运行C++程序出现"段错误(核心已转储)"的原因
今天写程序出现了“段错误(核心已转储)"的问题,查了一下资料,加上自己的实践,总结了以下几个方面的原因. 1.内存访问出错 这类问题的典型代表就是数组越界. 2.非法内存访问 出现这类问题 ...
- Unsupported major.minor version 52.0 处理方式
Exception in thread "main" java.lang.UnsupportedClassVersionError: com/globalroam/openstac ...
- Oracle11g R2学习系列 之三教程选择
工欲善其事必先利其器,选择一本入门教程也是很重要的,本人使用的也是这位同事推荐的电子工业出版社的<<Oracle 实用教程(第3版)>>郑阿奇主编,可以至这里购买到,我个人还是 ...
- java 编码转换
在网络中爬取到的数据,编码可能与当前编译器的编码不相同,而导致可能产生显示乱码的问题.那么如何将网络的编码,转换为当前编译器认可的编码(一般为UTF-8),就是个问题了. 主要使用了两个方法: Str ...
- Lua 字符串函数小结
1.求字符串长度 string.len(str) 2.大小写转换 string.upper(str) string.lower(str) 3.字符串查找(非全局) --func_string.lua ...
- 用 C 语言编写 Windows 服务程序的五个步骤
Windows 服务被设计用于需要在后台运行的应用程序以及实现没有用户交互的任务.为了学习这种控制台应用程序的基础知识,C(不是C++)是最佳选择.本文将建立并实现一个简单的服务程序,其功能是查询系统 ...
- #define XBYTE ((unsigned char volatile xdata *) 0)
今天在看别人的CAN总线程序的时候,突然发现了这么一句宏定义:#define XBYTE ((unsigned char volatile xdata *) 0),以前都没注意到过.后来查了一下,发现 ...
- 关于hash
http://rapheal.iteye.com/blog/1142955 关于javascript hash
- position 为absolute时/float 为right,span为block
元素分为内联元素和区块元素两类(当然也有其它的),在内联元素中有个非常重要的常识,即内两元素是不可以设置区块元素所具有的样式,例如:width | height.relative : 原来是什么类型的 ...
- SGU 194 Reactor Cooling
http://acm.sgu.ru/problem.php?contest=0&problem=194 题意:m条有向边,有上下界,求最大流. 思路:原图中有u-v low[i],high[i ...