🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Quiz: Probability and Bayes: all 15 questions

Quiz: Probability and Bayes · Question 6 of 15

Why does Naive Bayes add log-probabilities instead of multiplying probabilities?

Why does Naive Bayes add log-probabilities instead of multiplying probabilities?

  1. A.Logs are more accurate in theory
  2. B.Multiplying many small numbers underflows to 0.0 on a computer; adding logs avoids that
  3. C.Python cannot multiply floats
  4. D.It makes the classifier less naive
Answer & explanation

Correct answer: Multiplying many small numbers underflows to 0.0 on a computer; adding logs avoids that

log(a × b) = log a + log b, and the sum stays in a safe range.

Can you get the rest right without peeking?

Take the timed Quiz: Probability and Bayes quiz free. Pass it to earn XP and count towards your certificate.

Start the quiz →