题目地址:http://acm.hdu.edu.cn/showproblem.php?pid=1021
说明 :题目很水
但是有一个重要结论,只要是递推数列,一定是模周期数列 (可以用抽屉原理证明)
#include<iostream>
using namespace std;
int main()
{
int n;
while(cin>>n)
{
if(n%8==2||n%8==6) cout<<"yes"<<endl;
else cout<<"no"<<endl;
}
}