結果
| 問題 |
No.920 あかあお
|
| コンテスト | |
| ユーザー |
courange_cou
|
| 提出日時 | 2020-01-12 12:09:23 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 631 bytes |
| コンパイル時間 | 236 ms |
| コンパイル使用メモリ | 31,232 KB |
| 実行使用メモリ | 6,824 KB |
| 最終ジャッジ日時 | 2024-11-28 15:02:13 |
| 合計ジャッジ時間 | 1,021 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 3 |
| other | WA * 11 |
ソースコード
#include <stdio.h>
int main(){
int X,Y,Z,ans=0;
scanf("%d %d %d",&X,&Y,&Z);
if(X>Y){
if((X-Y)<Z){
Z -= X-Y;
Y = X;
printf("パターン1\n");
}else{
ans = Y+Z;
printf("パターン2\n");
}
}else if(Y>X){
if((Y-X)<Z){
Z -= Y-X;
X = Y;
printf("パターン3\n");
}else{
ans = X+Z;
printf("パターン4\n");
}
}
printf("X:%d\nY:%d\nZ:%d\n",X,Y,Z);
if(X == Y){
if(Z % 2 == 1)ans += (Z-1)/2+X;
else ans += Z/2+X;
printf("パターン5\n");
}
printf("%d\n",ans);
}
courange_cou