結果

問題 No.207 世界のなんとか
ユーザー sen_fx
提出日時 2016-01-26 23:09:11
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
AC  
実行時間 2 ms / 5,000 ms
コード長 365 bytes
コンパイル時間 423 ms
コンパイル使用メモリ 55,508 KB
実行使用メモリ 5,248 KB
最終ジャッジ日時 2024-10-09 10:45:40
合計ジャッジ時間 1,068 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 19
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <string>
using namespace std;


int main()
{
	int a = 0, b = 0, c = 0;

	cin >> a >> b;

	//cout << (b + a - 1) / a << endl;

	for (int i = a; i <= b; i++)
	{
		// 3の倍数
		if (i % 3 == 0)
		{
			cout << i << endl;
		}
		// 3を含む
		else if(to_string(i).find('3') != string::npos)
		{
			cout << i << endl;
		}
	}

	return 0;
}
0