Skip to content

Conversation

@suyeun84
Copy link
Contributor

@suyeun84 suyeun84 commented Apr 4, 2025

🧷 문제 링크

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

🧭 풀이 시간

30분

👀 체감 난이도

✏️ 문제 설명

호석이가 디스플레이의 LED 중에서 최소 1개, 최대 P개를 반전시키려고 한다.
반전 이후 층은 1 이상 N 이하가 되어야하며,
현재 엘리베이터는 X층에 멈춰있다.

🔍 풀이 방법

digit 배열에 각 숫자로 바꾸려고 할 때 반전시켜야 하는 LED의 갯수 저장해두고,
dfs로 재귀를 돌면서 조건을 만족할 때, answer를 증가시킨다.

⏳ 회고

간단하게 생각하면 되는데, 괜히 복잡하게 생각해서 시간을 많이 잡아먹었다.

@suyeun84 suyeun84 added the timeout ⌚ 목표 시간보다 오래걸렸을 때 label Apr 4, 2025
@ShinHeeEul ShinHeeEul merged commit db6f9c1 into main Apr 4, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

timeout ⌚ 목표 시간보다 오래걸렸을 때

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants