Short Cake
8PM - Animal Crossing Wild World

사생활 보호 설정

https://gamjia.tistory.com

Mini Rooms

  • 내 미니룸
  • 미니미설정
  • 미니룸설정
  • 답글수 [0]

What Friends Say

한마디로 표현해봐~

1촌평 관리

1436번 영화감독 숌

GamJia 2023. 4. 3. 09:05

단계별로 풀어보기 - 브루트 포스 - 5단계

https://www.acmicpc.net/problem/1436

#include <iostream>
#include <string>
using namespace std;
int main()
{
    int N,count=0;
    cin>>N;
    
    for(int i=666;;i++)
    {
        if(to_string(i).find("666")!=-1)
        {
            count++;
        }
        if(N==count)
        {
            cout<<i;
            break;
        }        
    }
    return 0;
}

🔊 종말의 수 예시

666 1666... 6660 6661 6662... 6669...

'BaekJoon' 카테고리의 다른 글

2751번 수 정렬하기 2  (0) 2023.04.03
2750번 수 정렬하기  (0) 2023.04.03
1018번 체스판 다시 칠하기  (0) 2023.04.03
7568번 덩치  (0) 2023.04.03
2231번 분해합  (0) 2023.03.31