返回列表 發帖
  1. #include<bits/stdc++.h>
  2. using namespace std;
  3. int main()
  4. {
  5.     long int a,b,c;
  6.     while(cin>>a>>b>>c)
  7.     {
  8.         pair<long long int,char> candidate[3];
  9.         candidate[0]={a,'A'};
  10.         candidate[1]={b,'B'};
  11.         candidate[2]={c,'C'};
  12.         sort(candidate,candidate+3);
  13.         if(candidate[0].first+candidate[1].first>candidate[2].first)
  14.         {
  15.             cout<<candidate[1].second<<endl;
  16.         }
  17.         else
  18.         {
  19.             cout<<candidate[2].second<<endl;
  20.         }
  21.     }
  22.     return 0;
  23. }
複製代碼

TOP

返回列表