結果

問題 No.677 10^Nの約数
ユーザー youthfuldays072youthfuldays072
提出日時 2018-05-25 09:58:01
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 702 bytes
コンパイル時間 2,244 ms
コンパイル使用メモリ 74,940 KB
実行使用メモリ 56,444 KB
最終ジャッジ日時 2023-09-11 03:21:05
合計ジャッジ時間 5,861 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 127 ms
55,656 KB
testcase_01 AC 127 ms
55,704 KB
testcase_02 AC 125 ms
55,796 KB
testcase_03 AC 128 ms
55,652 KB
testcase_04 AC 129 ms
54,028 KB
testcase_05 AC 129 ms
55,944 KB
testcase_06 AC 131 ms
55,892 KB
testcase_07 AC 131 ms
55,948 KB
testcase_08 AC 131 ms
56,028 KB
testcase_09 AC 131 ms
55,916 KB
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Scanner;

public class Main {


    public static void main(String[] args) {

    	Main main=new Main();

    	main.run();

    }

    void run() {
    	Scanner sc=new Scanner(System.in);

    	int n=sc.nextInt();

    	List<Integer> ans=new ArrayList<Integer>();

    	for(int i2=0;i2<n+1;i2++) {
    		for(int i5=0;i5<n+1;i5++) {

    			int x=1;

    			for(int i=0;i<i2;i++) {
    				x*=2;
    			}

    			for(int i=0;i<i5;i++) {
    				x*=5;
    			}

    			ans.add(x);

    		}
    	}

    	Collections.sort(ans);

    	for(Integer i:ans) {
    		System.out.println(i);
    	}

    }



}





0