結果

問題 No.207 世界のなんとか
ユーザー DevbotBotDevbotBot
提出日時 2015-06-18 17:11:35
言語 Java21
(openjdk 21)
結果
AC  
実行時間 145 ms / 5,000 ms
コード長 351 bytes
コンパイル時間 2,287 ms
コンパイル使用メモリ 75,156 KB
実行使用メモリ 41,596 KB
最終ジャッジ日時 2024-04-17 16:17:09
合計ジャッジ時間 5,640 ms
ジャッジサーバーID
(参考情報)
judge3 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 135 ms
40,968 KB
testcase_01 AC 134 ms
41,136 KB
testcase_02 AC 140 ms
40,968 KB
testcase_03 AC 137 ms
41,184 KB
testcase_04 AC 136 ms
41,152 KB
testcase_05 AC 140 ms
41,148 KB
testcase_06 AC 137 ms
41,596 KB
testcase_07 AC 140 ms
41,540 KB
testcase_08 AC 138 ms
41,300 KB
testcase_09 AC 141 ms
41,100 KB
testcase_10 AC 142 ms
41,436 KB
testcase_11 AC 142 ms
41,020 KB
testcase_12 AC 144 ms
40,924 KB
testcase_13 AC 144 ms
41,004 KB
testcase_14 AC 145 ms
41,088 KB
testcase_15 AC 144 ms
41,412 KB
testcase_16 AC 136 ms
41,392 KB
testcase_17 AC 126 ms
40,252 KB
testcase_18 AC 135 ms
41,120 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;
class No207{
	public static void main(String args[]){
		Scanner sc = new Scanner(System.in);
		Long a = sc.nextLong();
		Long b = sc.nextLong();
		for (Long i = a; i <= b; i++){
			if (i % 3 == 0){
				System.out.println(i);
			} else {
				if (String.valueOf(i).indexOf("3") > -1) {
					System.out.println(i);
				}
			}
		}
	}
}
0