結果

問題 No.207 世界のなんとか
ユーザー ryosuke0825ryosuke0825
提出日時 2018-04-05 23:48:00
言語 Java21
(openjdk 21)
結果
AC  
実行時間 131 ms / 5,000 ms
コード長 304 bytes
コンパイル時間 4,221 ms
コンパイル使用メモリ 72,820 KB
実行使用メモリ 56,532 KB
最終ジャッジ日時 2023-09-08 17:53:03
合計ジャッジ時間 6,478 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 121 ms
56,044 KB
testcase_01 AC 121 ms
56,532 KB
testcase_02 AC 126 ms
55,972 KB
testcase_03 AC 124 ms
55,736 KB
testcase_04 AC 123 ms
55,940 KB
testcase_05 AC 119 ms
55,892 KB
testcase_06 AC 117 ms
55,828 KB
testcase_07 AC 119 ms
55,848 KB
testcase_08 AC 118 ms
55,472 KB
testcase_09 AC 123 ms
55,448 KB
testcase_10 AC 125 ms
56,496 KB
testcase_11 AC 131 ms
55,860 KB
testcase_12 AC 124 ms
56,060 KB
testcase_13 AC 125 ms
55,456 KB
testcase_14 AC 127 ms
56,148 KB
testcase_15 AC 126 ms
56,516 KB
testcase_16 AC 121 ms
55,968 KB
testcase_17 AC 122 ms
56,348 KB
testcase_18 AC 118 ms
55,756 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class No207 {

	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(i%3==0 || String.valueOf(i).contains("3")) {
				System.out.println(i);
			}
		}
	}

}
0