結果
| 問題 | No.207 世界のなんとか |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-03-05 21:21:04 |
| 言語 | Java (openjdk 25.0.2) |
| 結果 |
AC
|
| 実行時間 | 59 ms / 5,000 ms |
| コード長 | 541 bytes |
| 記録 | |
| コンパイル時間 | 2,610 ms |
| コンパイル使用メモリ | 82,872 KB |
| 実行使用メモリ | 41,984 KB |
| 最終ジャッジ日時 | 2026-04-23 13:55:03 |
| 合計ジャッジ時間 | 4,728 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 19 |
ソースコード
import java.io.IOException;
import java.util.Scanner;
public class No00000207_Main {
public static void main(String[] args) throws IOException {
Scanner scan = new Scanner(System.in);
int a = scan.nextInt();
int b = scan.nextInt();
for(int i = a; i <= b; i++) {
if(i % 3 == 0 || with3(String.valueOf(i))) {
System.out.println(i);
}
}
scan.close();
}
private static boolean with3(String str) {
for(int i = 0; i < str.length(); i++) {
if(str.charAt(i) == '3') {
return true;
}
}
return false;
}
}