結果
問題 | No.383 レーティング |
ユーザー |
|
提出日時 | 2021-02-17 23:04:18 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 154 ms / 2,000 ms |
コード長 | 336 bytes |
コンパイル時間 | 2,783 ms |
コンパイル使用メモリ | 76,744 KB |
実行使用メモリ | 42,032 KB |
最終ジャッジ日時 | 2024-09-14 07:52:30 |
合計ジャッジ時間 | 5,083 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 14 |
ソースコード
import java.util.*;public class Main {public static void main(String[] args) {Scanner sc = new Scanner(System.in);int a=sc.nextInt();int b=sc.nextInt();if(a > b){System.out.println("-" + (a-b));}else if(a < b){System.out.println("+" + (b-a));}else{System.out.println(a-b);}sc.close();}}