結果

問題 No.388 階段 (1)
ユーザー ダンネックダンネック
提出日時 2020-05-24 12:47:20
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 420 bytes
コンパイル時間 2,796 ms
コンパイル使用メモリ 75,556 KB
実行使用メモリ 54,236 KB
最終ジャッジ日時 2024-04-19 12:00:21
合計ジャッジ時間 5,085 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 116 ms
41,404 KB
testcase_01 WA -
testcase_02 AC 116 ms
41,544 KB
testcase_03 WA -
testcase_04 AC 113 ms
41,320 KB
testcase_05 AC 109 ms
40,084 KB
testcase_06 AC 110 ms
41,272 KB
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 AC 112 ms
41,392 KB
testcase_11 WA -
testcase_12 WA -
testcase_13 AC 102 ms
41,388 KB
testcase_14 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Arrays;
import java.util.Scanner;
public class length{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
	    int a = sc.nextInt();
	    int b = sc.nextInt();
	    int f = a / b;
	    if(a % b ==0){
	        System.out.println(f + 1);
	    }else if(f != 0){
	        System.out.println(f);
	    }else{
	        System.out.println("1");
	    }
		sc.close();
    }
}
0