結果

問題 No.46 はじめのn歩
ユーザー eagle
提出日時 2022-05-26 14:16:03
言語 Java
(openjdk 23)
結果
AC  
実行時間 121 ms / 5,000 ms
コード長 368 bytes
コンパイル時間 1,720 ms
コンパイル使用メモリ 74,792 KB
実行使用メモリ 41,232 KB
最終ジャッジ日時 2024-09-20 14:59:14
合計ジャッジ時間 3,348 ms
ジャッジサーバーID
(参考情報)
judge4 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 10
権限があれば一括ダウンロードができます

ソースコード

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