結果

問題 No.441 和か積
ユーザー tentententen
提出日時 2020-09-12 23:18:45
言語 Java21
(openjdk 21)
結果
AC  
実行時間 120 ms / 1,000 ms
コード長 631 bytes
コンパイル時間 2,083 ms
コンパイル使用メモリ 72,124 KB
実行使用メモリ 56,332 KB
最終ジャッジ日時 2023-08-30 19:34:28
合計ジャッジ時間 7,743 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 115 ms
55,712 KB
testcase_01 AC 113 ms
55,908 KB
testcase_02 AC 115 ms
55,572 KB
testcase_03 AC 117 ms
55,852 KB
testcase_04 AC 119 ms
55,736 KB
testcase_05 AC 119 ms
55,980 KB
testcase_06 AC 118 ms
55,728 KB
testcase_07 AC 116 ms
55,608 KB
testcase_08 AC 113 ms
55,864 KB
testcase_09 AC 113 ms
55,836 KB
testcase_10 AC 118 ms
55,844 KB
testcase_11 AC 116 ms
55,912 KB
testcase_12 AC 115 ms
55,588 KB
testcase_13 AC 114 ms
55,804 KB
testcase_14 AC 117 ms
55,828 KB
testcase_15 AC 117 ms
55,336 KB
testcase_16 AC 115 ms
55,588 KB
testcase_17 AC 115 ms
55,540 KB
testcase_18 AC 118 ms
55,620 KB
testcase_19 AC 114 ms
55,892 KB
testcase_20 AC 117 ms
55,748 KB
testcase_21 AC 117 ms
53,888 KB
testcase_22 AC 117 ms
55,420 KB
testcase_23 AC 117 ms
55,684 KB
testcase_24 AC 118 ms
55,728 KB
testcase_25 AC 118 ms
56,040 KB
testcase_26 AC 116 ms
55,636 KB
testcase_27 AC 114 ms
55,408 KB
testcase_28 AC 118 ms
55,692 KB
testcase_29 AC 119 ms
56,332 KB
testcase_30 AC 117 ms
55,848 KB
testcase_31 AC 118 ms
55,944 KB
testcase_32 AC 120 ms
55,952 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main {
	public static void main (String[] args) {
    	Scanner sc = new Scanner(System.in);
    	String a = sc.next();
    	String b = sc.next();
    	int aInt;
    	if (a.length() == 1) {
    	    aInt = Integer.parseInt(a);
    	} else {
    	    aInt = 3;
    	}
    	int bInt;
    	if (b.length() == 1) {
    	    bInt = Integer.parseInt(b);
    	} else {
    	    bInt = 3;
    	}
    	if (aInt * bInt == aInt + bInt) {
    	    System.out.println("E");
    	} else if (aInt * bInt > aInt + bInt) {
    	    System.out.println("P");
    	} else {
    	    System.out.println("S");
    	}
	}
}
0