Start: Jul, 10, 2019 08:30:00
2019年度暑期短学期达标测试补考
End: Jul, 10, 2019 11:30:00
Time elapsed:
Time remaining:

Problem_ID: E
Result: Accepted
Time: 40ms
Memory: 1592kB
Author: 2018212212186
In contest: 1284

#include<stdio.h>
int fbnq(int x);
void bj(int a[]);
int a[121399]={0};
int main()
{
    int n;
    bj(a);
    while(scanf("%d",&n)!=EOF){
    	if(a[n]==1){
    		printf("Lucky Day\n");
		}else{
			printf("Bad Day\n");
		}
	}
    return 0;
}
void bj(int a[])
{
	int i;
	for(i=1;i<25;i++){
		a[fbnq(i)]=1;
	}
}
int fbnq(int x)
{
	if(x==1||x==2){
		return x;
	}else{
		return fbnq(x-1)+fbnq(x-2);
	}
}