結果

問題 No.46 はじめのn歩
ユーザー dogwood0424
提出日時 2017-11-27 20:56:01
言語 Java
(openjdk 23)
結果
AC  
実行時間 133 ms / 5,000 ms
コード長 325 bytes
コンパイル時間 3,633 ms
コンパイル使用メモリ 74,008 KB
実行使用メモリ 41,508 KB
最終ジャッジ日時 2024-11-27 11:24:37
合計ジャッジ時間 5,637 ms
ジャッジサーバーID
(参考情報)
judge2 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 10
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class No46 {
	public static void main(String[]args) {
		Scanner s = new Scanner(System.in);

		int a = s.nextInt();
		int b = s.nextInt();
		int c = 0;
		int d = 0;

		c = b/a;
		d = b%a;
		if(d != 0) {
			System.out.println(c+1);
		}
		else if (d == 0) {
			System.out.println(c);
		}
	}

}
0