結果

問題 No.46 はじめのn歩
ユーザー eagleeagle
提出日時 2022-05-26 14:16:03
言語 Java21
(openjdk 21)
結果
AC  
実行時間 131 ms / 5,000 ms
コード長 368 bytes
コンパイル時間 5,557 ms
コンパイル使用メモリ 73,624 KB
実行使用メモリ 57,504 KB
最終ジャッジ日時 2023-10-20 19:25:47
合計ジャッジ時間 4,123 ms
ジャッジサーバーID
(参考情報)
judge11 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 130 ms
57,440 KB
testcase_01 AC 131 ms
57,396 KB
testcase_02 AC 130 ms
55,528 KB
testcase_03 AC 129 ms
57,312 KB
testcase_04 AC 128 ms
57,384 KB
testcase_05 AC 129 ms
55,424 KB
testcase_06 AC 130 ms
57,444 KB
testcase_07 AC 130 ms
57,124 KB
testcase_08 AC 130 ms
57,504 KB
testcase_09 AC 131 ms
56,920 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner sc = new Scanner(System.in);
		//一歩の歩幅
		int a = sc.nextInt();
		//歩く距離
		int b = sc.nextInt();
		//歩数
		int step = b / a;
		if(b % a != 0) {
			step++;
		}
		System.out.println(step);
	}
}
0