Prime Convergence
CodeChefOpen on judge ↗
You have two numbers, $x, y \in \mathbb{N}$. Your task is to find the minimum number of operations that is applied on $x$ and $y$ separately (but counted in total) such that they arrive at a constant number $z \in \mathbb{N}$, where $z$ is any arbitrary number. You "arrive" at $z$ by iteratively multiplying or dividing $x$ and/or $y$. This can be visualized as such: $(\alpha_0 x,\beta_0y) → (\al
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.
Sign in to chat with the tutor and save your progress.
Sign in to start