×
解除綁定,重新設定系統帳號的密碼
您的系統帳號 ID:
您的系統帳號:
您的帳號暱稱:
設定新密碼:
設定新密碼:
×
請輸入要加入的「課程代碼」
請向開設課程的使用者索取「課程代碼」
分類題庫
解題動態
排行榜
討論區
競賽區
登入
註冊
發表新討論
#9141: VC++ 一直輸出吉
zxc8976
(拘束)
學校 : 臺北市私立開南高級商工職業學校
編號 : 40067
×
傳送站內訊息
傳給:
主題:
內容:
來源 : [1.162.46.1]
最後登入時間 :
2014-09-03 21:55:33
a003.
兩光法師占卜術
| From: [1.160.19.231] | 發表日期 : 2014-09-03 17:29
#include <iostream>
using namespace std;
int main()
{
int M;
int D;
int S;
while( cin>>M){
cin>>D;
S=(M*2+D)%3;
if(S=0)
cout<<"普通"<<endl;
else if(S=1)
cout<<"吉"<<endl;
else
cout<<"大吉"<<endl;
}
return 0;
}
#9241: Re:VC++ 一直輸出吉
hugo8642612
(Hugowwwwwww)
學校 : 國立中央大學
編號 : 38705
×
傳送站內訊息
傳給:
主題:
內容:
來源 : [1.172.169.191]
最後登入時間 :
2023-02-04 01:50:43
a003.
兩光法師占卜術
| From: [114.39.17.43] | 發表日期 : 2014-09-25 22:07
#include
using namespace std;
int main()
{
int M;
int D;
int S;
while( cin>>M){
cin>>D;
S=(M*2+D)%3;
if(S==0)
cout<<"普通"<
else if(S==1)
cout<<"吉"<
else
cout<<"大吉"<
}
return 0;
}
ZeroJudge Forum