Taene's
[백준] 실버5-영화감독 숌 C++ 1436번 본문
https://www.acmicpc.net/problem/1436
#include <iostream>
#include <string>
using namespace std;
int main()
{
ios::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
int n;
cin >> n;
int i = 666;
while (true)
{
if (to_string(i).find("666") != string::npos)
n--;
if (n == 0) break;
i++;
}
cout << i;
return 0;
}'백준 > 실버' 카테고리의 다른 글
| [백준] 실버1-효율적인 해킹 C++ 1325번 (0) | 2025.02.24 |
|---|---|
| [백준] 실버4-수학숙제 C++ 2870번 (0) | 2025.02.23 |
| [백준] 실버5-비밀번호 발음하기 C++ 4659번 (0) | 2025.02.23 |
| [백준] 실버3-빈도 정렬 C++ 2910번 (0) | 2025.02.23 |
| [백준] 실버5-사과 담기 게임 C++ 2828번 (0) | 2025.02.23 |