#30269: c++解法


milk_wu (milk(訂閱訂起來))

學校 : 新北市立中山國中
編號 : 183114
來源 : [163.20.41.252]
最後登入時間 :
2022-09-28 17:33:31
a003. 兩光法師占卜術 | From: [111.71.16.241] | 發表日期 : 2022-05-14 13:57

#include <iostream>

using namespace std;

int main()
{
    int a, b, c;
    cin >> a >> b;
    c = (a*2+b)%3;
    if (c==0)
    {
        cout << " 普通" <<endl;
    }
    else if (c == 1)
    {
        cout << " 吉" <<endl;
    }
    else if (c == 2)
    {
        cout << " 大吉" <<endl;
    }
    return 0;
}

 
ZeroJudge Forum