POJ 2661

 1 #include<iostream>
 2 #include<stdio.h>
 3 using namespace std;
 4 
 5 int main()
 6 {
 7     //freopen("acm.acm","r",stdin);
 8     int a[21] = {3,5,8,12,20,34,57,98,170,300,536,966,1754,3210,5910,10944,20366,38064,71421,134480,254016};
 9     int num;
10     while(cin>>num,num)
11     {
12         num -= 1960;
13         num /= 10;
14         cout<<a[num]<<endl;
15     }
16 }
原文地址:https://www.cnblogs.com/gavinsp/p/4568633.html