CameraIcon
CameraIcon
SearchIcon
MyQuestionIcon
MyQuestionIcon
114
You visited us 114 times! Enjoying our articles? Unlock Full Access!
Question

A software company employs 3 programmers A, B and C. For the duration of a particular project, A, B and C worked 30%, 50% and 20% respectively. The probability of python programming language being used by A, B and C is 5%, 10% and 15% respectively. Find the probability that a particular piece of code chosen randomly is written by A given that it is in python language.

A
0.157
Right on! Give the BNAT exam to get a 100% scholarship for BYJUS courses
B
0.239
No worries! We‘ve got your back. Try BYJU‘S free classes today!
C
0.175
No worries! We‘ve got your back. Try BYJU‘S free classes today!
D
0.186
No worries! We‘ve got your back. Try BYJU‘S free classes today!
Open in App
Solution

The correct option is A 0.157
Let us define the following events: D: ‘the code is in python programming language’. E1: ‘A worked on the project’.E2: ‘B worked on the project’. E3: ‘C worked on the project’.

Then P(E1)= 0.3, P(E2)=0.5, P(E3)=0.2andP(D|E1)=0.05, P(D|E2)=0.1, P(D|E3)=0.15

We can infer that E1, E2 and E3 are mutually exclusive and exhaustive events and hence, represent partition of sample space.We have to find P(E1|D).By Bayes' theorem, we haveP(E1|D)=P(D|E1) P(E1)P(D|E1) P(E1) + P(D|E2) P(E2) + P(D|E3) P(E3)⇒ P(E1|D)=0.05×0.3 0.05×0.3 + 0.1×0.5 + 0.15×0.2⇒ P(E1|D)=0.0150.015 + 0.05 + 0.03⇒ P(E1|D)=1595=0.157Hence, the required probability is 0.157.

flag
Suggest Corrections
thumbs-up
0
similar_icon
Similar questions
View More
Join BYJU'S Learning Program
similar_icon
Related Videos
thumbnail
lock
Bayes Theorem
MATHEMATICS
Watch in App
Join BYJU'S Learning Program
CrossIcon