- #include <iostream>
- #include <cstdlib>
- using namespace std;
- int main ()
- {
- while(true)
- {
- int M, D ,S;
- cout<<"輸入一個月份:";
- cin>>M ;
- cout<<"輸入一個日期:";
- cin>>D;
- S = (M * 2 + D)% 3;
- if (S == 0)
- {
- cout<<"普通"<<endl;
- }
- else if(S == 1)
- {
- cout<<"吉"<<endl;
- }
- else if (S == 2)
- {
- cout<<"大吉"<<endl;
- }
- else
- {
- cout<<"........."<<endl;
- }
-
- system ("pause");
- }
- return 0;
- }
複製代碼 |