Skip to content

Conversation

@Seol-JY
Copy link
Contributor

@Seol-JY Seol-JY commented Nov 22, 2025

🧷 문제 링크

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

🧭 풀이 시간

35분

👀 체감 난이도

✏️ 문제 설명

0번 계단에서 시작하여 정확히 K번의 행동으로 N번 계단에 도달해야 함

아래 행동 가능:

  1. 계단 한 칸 올라가기: i → i + 1
  2. 지팡이 두드리기: i → i + floor(i/2)

🔍 풀이 방법

BFS를 활용하여 각 계단에 도달하는 최소 횟수를 계산

1번 계단에서 지팡이를 두드리면 1 + floor(1/2) = 1로 제자리
-> N에 도달하는 최소 횟수가 K 이하이면, 남는 횟수는 1번 계단에서 지팡이를 두드려 소모 가능
-> 최소 도달 횟수 <= K이면 minigimbob 출력

⏳ 회고

1번 계단에서 지팡이가 제자리라는 점을 파악하면 단순히 최소 횟수만 비교하면 됨
ez

@ShinHeeEul ShinHeeEul merged commit 547bc14 into main Nov 22, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants