結果
| 問題 | No.677 10^Nの約数 |
| コンテスト | |
| ユーザー |
youthfuldays072
|
| 提出日時 | 2018-05-25 09:58:01 |
| 言語 | Java (openjdk 23) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 702 bytes |
| 記録 | |
| コンパイル時間 | 1,931 ms |
| コンパイル使用メモリ | 75,816 KB |
| 実行使用メモリ | 55,096 KB |
| 最終ジャッジ日時 | 2024-06-28 17:52:37 |
| 合計ジャッジ時間 | 5,079 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 8 WA * 9 |
ソースコード
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);
}
}
}
youthfuldays072