結果

問題 No.383 レーティング
ユーザー uafr_csuafr_cs
提出日時 2016-07-01 22:21:46
言語 Java19
(openjdk 21)
結果
AC  
実行時間 148 ms / 2,000 ms
コード長 422 bytes
コンパイル時間 2,529 ms
コンパイル使用メモリ 77,704 KB
実行使用メモリ 56,708 KB
最終ジャッジ日時 2023-08-02 05:05:10
合計ジャッジ時間 5,853 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 148 ms
56,488 KB
testcase_01 AC 141 ms
56,544 KB
testcase_02 AC 112 ms
55,900 KB
testcase_03 AC 145 ms
56,236 KB
testcase_04 AC 147 ms
56,708 KB
testcase_05 AC 142 ms
56,692 KB
testcase_06 AC 144 ms
56,276 KB
testcase_07 AC 141 ms
56,660 KB
testcase_08 AC 138 ms
56,516 KB
testcase_09 AC 141 ms
56,676 KB
testcase_10 AC 145 ms
56,680 KB
testcase_11 AC 147 ms
56,280 KB
testcase_12 AC 148 ms
56,684 KB
testcase_13 AC 143 ms
56,688 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Arrays;
import java.util.HashSet;
import java.util.LinkedList;
import java.util.Scanner;
import java.util.Set;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		final int a = sc.nextInt();
		final int b = sc.nextInt();
		
		if(a != b){
			System.out.println((a < b ? "+" : "-") + Math.abs(a - b));
		}else{
			System.out.println("0");
		}
		
	}

}
0