結果

問題 No.207 世界のなんとか
ユーザー yun_appyun_app
提出日時 2016-05-12 11:34:15
言語 Java21
(openjdk 21)
結果
AC  
実行時間 57 ms / 5,000 ms
コード長 693 bytes
コンパイル時間 2,180 ms
コンパイル使用メモリ 74,400 KB
実行使用メモリ 37,116 KB
最終ジャッジ日時 2024-04-17 16:45:50
合計ジャッジ時間 3,786 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 53 ms
36,908 KB
testcase_01 AC 52 ms
36,820 KB
testcase_02 AC 54 ms
36,920 KB
testcase_03 AC 53 ms
36,864 KB
testcase_04 AC 52 ms
36,964 KB
testcase_05 AC 53 ms
36,892 KB
testcase_06 AC 57 ms
36,400 KB
testcase_07 AC 53 ms
36,768 KB
testcase_08 AC 51 ms
36,660 KB
testcase_09 AC 57 ms
36,396 KB
testcase_10 AC 52 ms
37,116 KB
testcase_11 AC 51 ms
36,908 KB
testcase_12 AC 52 ms
37,084 KB
testcase_13 AC 53 ms
36,800 KB
testcase_14 AC 52 ms
37,076 KB
testcase_15 AC 51 ms
36,736 KB
testcase_16 AC 50 ms
36,672 KB
testcase_17 AC 50 ms
37,100 KB
testcase_18 AC 52 ms
36,716 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

/* package whatever; // don't place package name! */

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

/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
    public static void main (String[] args) throws java.lang.Exception
    {
        // your code goes here
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] lines = br.readLine().split(" ");
        long a = Long.parseLong(lines[0]);
        long b = Long.parseLong(lines[1]);
        for(long i=a;i<=b;i++){
            if(i%3l == 0 || Long.toString(i).indexOf("3") >= 0){
                System.out.println(i);
            }
        }
    }

}
0