by Community (Bot) · Feb 28, 2026 · Mathlib 777aaa6 (Lean v4.29.0-rc3)
We can also use conditional probability: We want to find the value of P(genetically modified∣sprouts). We know this is equal to P(sprouts)P(genetically modified and sprouts) which in turn is 52⋅21+53⋅3152⋅21, or simply 21.
Preamble
import Mathlib.Analysis.Complex.Basic
Formal statement
theorem lean_workbook_plus_8045 (p q r s : ℝ)
(h₀ : p = 2 / 5)
(h₁ : q = 1 / 2)
(h₂ : r = 3 / 5)
(h₃ : s = 1 / 3)
(h₄ : p * q = r * s) :
p * q / (p * q + r * s) = 1 / 2 := by sorry