← All problemsSign in

Spiritual Chef

CodeChefRating 3028Open on judge ↗

Chef is on a spiritual journey, and plans to visit $N$ famous temples. At each temple, he wants to offer some flowers. Chef is determined to not show favoritism to any particular deity, and so will offer an equal number of flowers at each temple. Chef will only pluck flowers once, before he starts his journey. Before each temple lies a magical river, which **multiplies** the number of flowers

HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17

CodeSearch Tutor

Hints, not spoilers — it won’t hand over the full solution unless you insist.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start