結果
| 問題 |
No.333 門松列を数え上げ
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2016-04-03 22:47:39 |
| 言語 | Java (openjdk 23) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 532 bytes |
| コンパイル時間 | 2,088 ms |
| コンパイル使用メモリ | 74,052 KB |
| 実行使用メモリ | 54,120 KB |
| 最終ジャッジ日時 | 2024-10-02 13:04:43 |
| 合計ジャッジ時間 | 3,956 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 2 WA * 5 |
ソースコード
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
// 標準入力から読み込む際に、Scannerオブジェクトを使う。
Scanner sc = new Scanner(System.in);
// int 1つ分を読み込む
int a = sc.nextInt();
// int 1つ分を読み込む
int b = sc.nextInt();
int c=0;
if(a<b){
c=a-1;
}else if(a>b){
c=2000000000-a;
}
// 標準出力に書き出す。
System.out.println(c);
}
}