結果

問題 No.207 世界のなんとか
ユーザー AoiroFukurouAoiroFukurou
提出日時 2016-05-14 13:36:47
言語 Java21
(openjdk 21)
結果
AC  
実行時間 125 ms / 5,000 ms
コード長 331 bytes
コンパイル時間 2,950 ms
コンパイル使用メモリ 74,108 KB
実行使用メモリ 41,660 KB
最終ジャッジ日時 2024-04-17 16:46:01
合計ジャッジ時間 5,838 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 106 ms
41,512 KB
testcase_01 AC 121 ms
41,344 KB
testcase_02 AC 114 ms
41,512 KB
testcase_03 AC 111 ms
41,328 KB
testcase_04 AC 111 ms
41,504 KB
testcase_05 AC 111 ms
41,612 KB
testcase_06 AC 125 ms
41,260 KB
testcase_07 AC 120 ms
41,588 KB
testcase_08 AC 116 ms
41,388 KB
testcase_09 AC 110 ms
40,684 KB
testcase_10 AC 117 ms
41,152 KB
testcase_11 AC 109 ms
41,312 KB
testcase_12 AC 120 ms
40,440 KB
testcase_13 AC 124 ms
41,416 KB
testcase_14 AC 114 ms
41,324 KB
testcase_15 AC 123 ms
41,656 KB
testcase_16 AC 116 ms
41,472 KB
testcase_17 AC 105 ms
41,660 KB
testcase_18 AC 118 ms
41,468 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

package yukicoder;

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++){
		String s = Integer.toString(i);
		if(i%3==0||s.indexOf("3") != -1){
			System.out.println(i);
		}
	}
}
}
0