← All problemsSign in

Will Cersei die!

Arya is going to kill Cersei. Cersei, somehow from her sources, came to know about this. So, she made an army of $N$ soldiers and placed them in a line outside the Red Keep. Every soldier has a weapon in their hand and each weapon has a certain strength. Strengths of all these weapons is an array $[X_{1}, X_{2}, ...,X_{n}]$, where all $X_{i}$ are independent uniform random variables from $[0, 1]$.

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