#include <stdio.h>
long long int fib[51];
void creat()
{
int i;
fib[1] = 2, fib[2] = 3;
for (i = 3; i < 51; i ++)
fib[i] = fib[i - 1] + fib[i - 2];
}
int main()
{
creat();
int n, m, caseNum = 1;
scanf("%d", &n);
while (n --)
{
scanf("%d", &m);
printf("Scenario #%d:\n", caseNum ++);
printf("%lld\n\n", fib[m]);
}
return 0;
}
回目錄
回首頁
沒有留言 :
張貼留言