結果
問題 | No.2239 Friday |
ユーザー | Asahi |
提出日時 | 2023-03-10 21:28:07 |
言語 | Java21 (openjdk 21) |
結果 |
WA
|
実行時間 | - |
コード長 | 507 bytes |
コンパイル時間 | 2,877 ms |
コンパイル使用メモリ | 74,228 KB |
実行使用メモリ | 57,672 KB |
最終ジャッジ日時 | 2023-10-18 07:08:39 |
合計ジャッジ時間 | 6,312 ms |
ジャッジサーバーID (参考情報) |
judge14 / judge11 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 131 ms
57,384 KB |
testcase_01 | AC | 130 ms
57,580 KB |
testcase_02 | WA | - |
testcase_03 | WA | - |
testcase_04 | WA | - |
testcase_05 | AC | 131 ms
57,592 KB |
testcase_06 | WA | - |
testcase_07 | WA | - |
testcase_08 | AC | 132 ms
57,420 KB |
testcase_09 | WA | - |
testcase_10 | WA | - |
testcase_11 | WA | - |
testcase_12 | AC | 130 ms
57,564 KB |
testcase_13 | AC | 130 ms
57,636 KB |
testcase_14 | WA | - |
testcase_15 | AC | 131 ms
57,336 KB |
testcase_16 | AC | 131 ms
57,404 KB |
testcase_17 | WA | - |
testcase_18 | AC | 133 ms
57,392 KB |
testcase_19 | WA | - |
ソースコード
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); int a = scanner.nextInt(); // アジフライの数 int b = scanner.nextInt(); // エビフライの数 int naturalDishes = Math.min(a, b) + (Math.abs(a - b) / 2); // 自然な皿の枚数 int difference = Math.abs(a - b) % 2; // 自然な皿の枚数と不自然な皿の枚数の差 System.out.println(difference); } }