結果

問題 No.1027 U+1F4A0
ユーザー tetsuyanatetsuyana
提出日時 2020-04-24 20:28:27
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 526 bytes
コンパイル時間 2,420 ms
コンパイル使用メモリ 74,664 KB
実行使用メモリ 54,608 KB
最終ジャッジ日時 2024-04-23 02:42:25
合計ジャッジ時間 5,468 ms
ジャッジサーバーID
(参考情報)
judge1 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 109 ms
53,872 KB
testcase_01 AC 103 ms
53,496 KB
testcase_02 AC 131 ms
54,288 KB
testcase_03 AC 134 ms
53,960 KB
testcase_04 AC 134 ms
54,100 KB
testcase_05 AC 129 ms
54,240 KB
testcase_06 AC 112 ms
53,816 KB
testcase_07 AC 129 ms
54,204 KB
testcase_08 AC 101 ms
52,752 KB
testcase_09 AC 110 ms
54,384 KB
testcase_10 AC 97 ms
52,836 KB
testcase_11 AC 107 ms
54,016 KB
testcase_12 AC 124 ms
54,076 KB
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 WA -
testcase_20 WA -
testcase_21 WA -
testcase_22 AC 106 ms
53,448 KB
testcase_23 AC 99 ms
52,624 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;
import java.io.PrintWriter;
import static java.lang.Integer.*;
import static java.lang.Long.*;
import static java.lang.Math.*;
import static java.lang.System.*;

public class Main {
	public static void main(String[] args) {
		int i,j;
		Scanner sc = new Scanner(in);
		int d1 = parseInt(sc.next());
		int d2 = parseInt(sc.next());
		sc.close();
		int d12 = d1*d1;
		int d22 = d2*d2;
		int ans=0;
		if(d12==d22 || d12==d2) {
			ans = 4;
		} else if(d22>d12&&d12>d2) {
			ans=8;
		}
		out.println(ans);
	}
}
0