HustOJ - 1017

 1 #include<iostream> 
 2 #include<set>
 3 using namespace std;
 4 int main()
 5 {
 6     int s=0;
 7     int F=479001600;
 8     multiset<unsigned int> a;
 9     int n;
10     while(cin>>n)
11     {
12         if(F%n==0)
13         {
14             multiset<unsigned int>::iterator v=a.find(F/n);
15             if(v!=a.end())
16             {
17                 s++;
18                 a.erase(v);
19             }
20             else
21                 a.insert(n);
22         }
23         if(cin.get()=='\0')
24         {
25             break;
26         }
27     }
28     cout<<s<<endl;
29     return 0;
30 }
1017 12!配 对

 

posted @ 2017-05-04 12:44  浮华散丶  阅读(70)  评论(0编辑  收藏  举报