結果

問題 No.485 方程式のお勉強
ユーザー 水野嶺水野嶺
提出日時 2020-05-28 16:35:53
言語 Java21
(openjdk 21)
結果
AC  
実行時間 136 ms / 2,000 ms
コード長 338 bytes
コンパイル時間 2,562 ms
コンパイル使用メモリ 73,756 KB
実行使用メモリ 41,284 KB
最終ジャッジ日時 2024-04-21 05:43:38
合計ジャッジ時間 5,779 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 130 ms
41,036 KB
testcase_01 AC 127 ms
41,108 KB
testcase_02 AC 115 ms
39,760 KB
testcase_03 AC 113 ms
39,944 KB
testcase_04 AC 121 ms
40,756 KB
testcase_05 AC 122 ms
40,968 KB
testcase_06 AC 114 ms
39,924 KB
testcase_07 AC 113 ms
40,064 KB
testcase_08 AC 136 ms
41,284 KB
testcase_09 AC 135 ms
40,968 KB
testcase_10 AC 116 ms
39,812 KB
testcase_11 AC 125 ms
40,916 KB
testcase_12 AC 110 ms
40,036 KB
testcase_13 AC 122 ms
40,768 KB
testcase_14 AC 120 ms
40,852 KB
testcase_15 AC 111 ms
39,952 KB
testcase_16 AC 123 ms
40,892 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;
import java.lang.*;
import java.io.*;

class Main
{
	public static void main (String[] args) 
	{
		// 入力値の読み込み
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		int ans =b/a;
		if(b%a==0){
			System.out.println(ans);
		}else{
			System.out.println("NO");
		}
	}
}
0