結果
問題 | No.333 門松列を数え上げ |
ユーザー | mitsuo |
提出日時 | 2016-05-04 13:39:34 |
言語 | Java21 (openjdk 21) |
結果 |
WA
|
実行時間 | - |
コード長 | 509 bytes |
コンパイル時間 | 2,279 ms |
コンパイル使用メモリ | 75,124 KB |
実行使用メモリ | 56,120 KB |
最終ジャッジ日時 | 2024-04-15 11:17:06 |
合計ジャッジ時間 | 4,279 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 135 ms
41,424 KB |
testcase_01 | AC | 136 ms
41,656 KB |
testcase_02 | WA | - |
testcase_03 | WA | - |
testcase_04 | AC | 133 ms
41,612 KB |
testcase_05 | AC | 141 ms
41,748 KB |
testcase_06 | AC | 139 ms
41,356 KB |
testcase_07 | AC | 134 ms
41,736 KB |
testcase_08 | AC | 136 ms
41,496 KB |
ソースコード
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); String[] input = new String[1]; int i = 0; while (sc.hasNext()) { input[i] = sc.nextLine(); i++; } System.out.println(solve(input)); sc.close(); } public static long solve(String[] in) { long a = Long.valueOf(in[0].split(" ")[0]); long b = Long.valueOf(in[0].split(" ")[1]); if(a < b){ return a - 1; }else{ return 2000000000 - b - 1; } } }