結果

問題 No.136 Yet Another GCD Problem
ユーザー fjafjafjafjafjafja
提出日時 2017-10-01 12:10:33
言語 Java21
(openjdk 21)
結果
AC  
実行時間 130 ms / 5,000 ms
コード長 293 bytes
コンパイル時間 4,858 ms
コンパイル使用メモリ 71,720 KB
実行使用メモリ 55,924 KB
最終ジャッジ日時 2023-08-09 23:14:39
合計ジャッジ時間 11,366 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 126 ms
55,900 KB
testcase_01 AC 126 ms
55,320 KB
testcase_02 AC 127 ms
55,696 KB
testcase_03 AC 127 ms
55,824 KB
testcase_04 AC 127 ms
55,876 KB
testcase_05 AC 129 ms
55,608 KB
testcase_06 AC 126 ms
55,744 KB
testcase_07 AC 125 ms
55,892 KB
testcase_08 AC 126 ms
55,312 KB
testcase_09 AC 126 ms
55,728 KB
testcase_10 AC 125 ms
55,428 KB
testcase_11 AC 125 ms
55,740 KB
testcase_12 AC 127 ms
55,276 KB
testcase_13 AC 125 ms
55,584 KB
testcase_14 AC 129 ms
55,924 KB
testcase_15 AC 129 ms
55,724 KB
testcase_16 AC 126 ms
55,832 KB
testcase_17 AC 126 ms
55,720 KB
testcase_18 AC 130 ms
55,720 KB
testcase_19 AC 125 ms
55,696 KB
testcase_20 AC 126 ms
55,628 KB
testcase_21 AC 123 ms
55,780 KB
testcase_22 AC 124 ms
55,672 KB
testcase_23 AC 123 ms
53,780 KB
testcase_24 AC 125 ms
55,652 KB
testcase_25 AC 124 ms
55,704 KB
testcase_26 AC 123 ms
55,816 KB
testcase_27 AC 125 ms
55,636 KB
testcase_28 AC 124 ms
55,704 KB
testcase_29 AC 124 ms
55,708 KB
testcase_30 AC 125 ms
55,916 KB
testcase_31 AC 123 ms
55,476 KB
testcase_32 AC 125 ms
55,636 KB
testcase_33 AC 125 ms
55,700 KB
testcase_34 AC 123 ms
55,672 KB
testcase_35 AC 123 ms
55,712 KB
testcase_36 AC 123 ms
55,640 KB
testcase_37 AC 125 ms
55,844 KB
testcase_38 AC 123 ms
55,888 KB
testcase_39 AC 123 ms
54,168 KB
testcase_40 AC 123 ms
55,736 KB
testcase_41 AC 123 ms
55,584 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class N136 {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n=sc.nextInt(),k=sc.nextInt();
		int i=2;
		int ans=0;
		while(true){
			if(n%i==0){
				ans=n/i;
				break;
			}
			i++;
		}
		System.out.println(ans);
	}

}
0