标签:
1 #include<iostream> 2 #include<cstdio> 3 using namespace std; 4 int main() 5 { 6 long long a[52]; 7 int i; 8 a[1]=1,a[2]=2; 9 for(i=3;i<51;i++) 10 a[i]=a[i-1]+a[i-2]; 11 int T; 12 int c,d; 13 cin>>T; 14 while(T--) 15 { 16 cin>>c>>d; 17 cout<<a[d-c]<<endl; 18 } 19 }
标签:
原文地址:http://www.cnblogs.com/a1225234/p/4550047.html