結果
| 問題 |
No.920 あかあお
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-12-09 08:25:13 |
| 言語 | Java (openjdk 23) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 499 bytes |
| コンパイル時間 | 2,333 ms |
| コンパイル使用メモリ | 75,368 KB |
| 実行使用メモリ | 54,432 KB |
| 最終ジャッジ日時 | 2024-06-11 19:51:34 |
| 合計ジャッジ時間 | 4,522 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 8 WA * 3 |
ソースコード
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int x = Integer.parseInt(sc.next());
int y = Integer.parseInt(sc.next());
int z = Integer.parseInt(sc.next());
int res = 0;
if(x < y) {
res += x;
res += (y - x + z) / 2;
} else {
res += y;
res += (x - y + z) / 2;
}
System.out.println(res);
}
}