結果

問題 No.516 赤と青の風船
ユーザー GrenacheGrenache
提出日時 2017-05-28 21:21:56
言語 Java21
(openjdk 21)
結果
AC  
実行時間 113 ms / 2,000 ms
コード長 696 bytes
コンパイル時間 3,660 ms
コンパイル使用メモリ 74,844 KB
実行使用メモリ 57,508 KB
最終ジャッジ日時 2023-10-21 14:00:34
合計ジャッジ時間 5,224 ms
ジャッジサーバーID
(参考情報)
judge12 / judge9
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 106 ms
56,284 KB
testcase_01 AC 110 ms
57,172 KB
testcase_02 AC 111 ms
57,400 KB
testcase_03 AC 113 ms
57,460 KB
testcase_04 AC 112 ms
57,400 KB
testcase_05 AC 110 ms
57,216 KB
testcase_06 AC 112 ms
57,508 KB
testcase_07 AC 108 ms
56,268 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.*;
import java.util.*;


public class Main_yukicoder516 {

	private static Scanner sc;
	private static Printer pr;

	private static void solve() {
		String[] s = new String[3];
		int r = 0;
		for (int i = 0; i < 3; i++) {
			s[i] = sc.next();
			if (s[i].equals("RED")) {
				r++;
			}
		}

		if (r > 1) {
			pr.println("RED");
		} else {
			pr.println("BLUE");
		}
	}

	// ---------------------------------------------------
	public static void main(String[] args) {
		sc = new Scanner(System.in);
		pr = new Printer(System.out);

		solve();

		pr.close();
		sc.close();
	}

	private static class Printer extends PrintWriter {
		Printer(PrintStream out) {
			super(out);
		}
	}
}
0