Optimal Reserve Price
CodeChefOpen on judge ↗
Lukas just bought a new phone so he has decided to sell his old phone. He needs to decide a price at which he will sell his phone. There are n prospective buyers and each one of them has a secret valuation for the phone which is unknown to Lukas. Analysing historical data,Lukas finds out that the valuation of each prospective buyer is a number chosen uniformly at random from [0,100] dollars. If th
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