NINJA
CodeChefOpen on judge ↗
The $Ninja$ is disciplined and hardworking. Today, he wants to improve his $climbing$ skills. Let each level of two buildings be denoted by arrays $A$ and $B$ each with size $N$ and $A[i]$ or $B[i]$ denotes the $maximum$ height up to which he can jump if he was on that level of that particular array. He wants to reach on the $top$ of either of the two $adjacent$ walls of $same$ height. Here top
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