結果

問題 No.383 レーティング
ユーザー cande398cande398
提出日時 2017-10-09 22:22:20
言語 Java21
(openjdk 21)
結果
AC  
実行時間 123 ms / 2,000 ms
コード長 255 bytes
コンパイル時間 2,148 ms
コンパイル使用メモリ 72,452 KB
実行使用メモリ 56,236 KB
最終ジャッジ日時 2023-08-10 21:20:56
合計ジャッジ時間 4,678 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 120 ms
56,080 KB
testcase_01 AC 123 ms
55,692 KB
testcase_02 AC 119 ms
55,772 KB
testcase_03 AC 121 ms
56,236 KB
testcase_04 AC 121 ms
55,916 KB
testcase_05 AC 121 ms
55,900 KB
testcase_06 AC 119 ms
56,044 KB
testcase_07 AC 119 ms
56,208 KB
testcase_08 AC 121 ms
56,088 KB
testcase_09 AC 122 ms
55,864 KB
testcase_10 AC 120 ms
55,972 KB
testcase_11 AC 120 ms
53,860 KB
testcase_12 AC 121 ms
55,768 KB
testcase_13 AC 122 ms
55,908 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int ans = 0-sc.nextInt()+sc.nextInt();
    if(ans == 0)System.out.println("0");
    else System.out.printf("%+d\n", ans);
  }
}
0