結果

問題 No.207 世界のなんとか
ユーザー cande398cande398
提出日時 2017-10-16 00:46:18
言語 Java21
(openjdk 21)
結果
AC  
実行時間 139 ms / 5,000 ms
コード長 326 bytes
コンパイル時間 2,039 ms
コンパイル使用メモリ 74,420 KB
実行使用メモリ 41,496 KB
最終ジャッジ日時 2024-04-28 22:13:56
合計ジャッジ時間 5,435 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 133 ms
41,352 KB
testcase_01 AC 129 ms
41,172 KB
testcase_02 AC 138 ms
41,204 KB
testcase_03 AC 134 ms
41,496 KB
testcase_04 AC 131 ms
41,168 KB
testcase_05 AC 136 ms
41,036 KB
testcase_06 AC 129 ms
41,200 KB
testcase_07 AC 132 ms
41,072 KB
testcase_08 AC 132 ms
40,896 KB
testcase_09 AC 135 ms
41,064 KB
testcase_10 AC 139 ms
41,380 KB
testcase_11 AC 135 ms
40,992 KB
testcase_12 AC 137 ms
41,016 KB
testcase_13 AC 138 ms
41,032 KB
testcase_14 AC 139 ms
41,184 KB
testcase_15 AC 136 ms
41,336 KB
testcase_16 AC 134 ms
41,172 KB
testcase_17 AC 129 ms
41,156 KB
testcase_18 AC 129 ms
41,076 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int A = sc.nextInt();
        int B = sc.nextInt();
        for(int i = A;i<=B;i++){
            if(String.valueOf(i).indexOf("3") != -1 || i%3 == 0)System.out.println(i);
        }
    }
}
0