返回列表 發帖
  1. #include<bits/stdc++.h>
  2. using namespace std;

  3. char a;
  4. string str[]={"摩羯座","水瓶座","雙魚座","牡羊座","金牛座","雙子座","巨蟹座","獅子座","處女座","天秤座","天蠍座","射手座","摩羯座"};
  5. int m,d,b[]={0,21,20,21,21,22,22,23,22,24,24,23,23};
  6. int main()
  7. {
  8.     cin.tie(0);
  9.     cin.sync_with_stdio(0);
  10.     while(cin>>m>>a>>d)
  11.     {
  12.         if(d>=b[m])
  13.         {
  14.             cout<<str[m]<<endl;
  15.         }else
  16.         {
  17.             cout<<str[m-1]<<endl;
  18.         }
  19.     }
  20.     return 0;
  21. }
複製代碼

TOP

返回列表