結果

問題 No.207 世界のなんとか
ユーザー jimanojimano
提出日時 2015-10-12 09:56:08
言語 Java21
(openjdk 21)
結果
AC  
実行時間 109 ms / 5,000 ms
コード長 353 bytes
コンパイル時間 2,979 ms
コンパイル使用メモリ 77,304 KB
実行使用メモリ 41,620 KB
最終ジャッジ日時 2024-04-17 16:28:21
合計ジャッジ時間 5,249 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 95 ms
41,096 KB
testcase_01 AC 104 ms
41,288 KB
testcase_02 AC 96 ms
41,068 KB
testcase_03 AC 107 ms
40,484 KB
testcase_04 AC 95 ms
41,388 KB
testcase_05 AC 98 ms
41,432 KB
testcase_06 AC 100 ms
41,124 KB
testcase_07 AC 102 ms
41,244 KB
testcase_08 AC 93 ms
41,052 KB
testcase_09 AC 108 ms
40,040 KB
testcase_10 AC 109 ms
40,724 KB
testcase_11 AC 105 ms
40,208 KB
testcase_12 AC 106 ms
39,784 KB
testcase_13 AC 107 ms
39,912 KB
testcase_14 AC 106 ms
41,620 KB
testcase_15 AC 108 ms
40,756 KB
testcase_16 AC 102 ms
41,148 KB
testcase_17 AC 94 ms
41,424 KB
testcase_18 AC 102 ms
40,788 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(isNabe(i)) System.out.println(i);
		}
	}
	
	static boolean isNabe(int i){
		return i % 3 == 0 || Integer.toString(i).contains("3");
	}
}
0