Probability
CodeChefOpen on judge ↗
Chef has recently started attending probability class. For the first three lectures he had no homework but for the fourth lecture he had one to do. The problem was given as range [A,B] over positive integers, chef has to find the probability of a number chosen at random within the range (including A and B) such that it will contain at least one zero. Input - The first line of the input contains
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